当前位置:网站首页>golang modules初始化项目
golang modules初始化项目
2022-07-30 14:39:00 【JavaPub-rodert】
博主介绍: 自媒体 JavaPub 独立维护人,全网粉丝15w+,csdn博客专家、java领域优质创作者,51ctoTOP10博主,知乎/掘金/华为云/阿里云/InfoQ等平台优质作者、专注于Java、
GoLang
技术领域和副业。
前言
环境:golang 1.18.3
设置代码
GOPROXY="https://goproxy.io,direct"
go modules 常用命令
go mod init # 初始化go.mod
go mod tidy # 更新依赖文件
go mod download # 下载依赖文件
go mod vendor # 执行此命令,会将刚才下载至 GOPATH 下的依赖复制至该项目根目录下的 vendor(自动新建) 文件夹下
go mod edit # 手动修改依赖文件
go mod graph # 打印依赖图
go mod verify # 校验依赖
边栏推荐
猜你喜欢
Desktop Software Development Framework Awards
JUC常见的线程池源码学习 02 ( ThreadPoolExecutor 线程池 )
使用 protobuf 进行数据序列化
开始学习C语言了
华为再发「天才少年」召集令!曾放弃360万年薪的他也来首秀
Interface automation framework, lm-easytest beta version released, use it quickly~
Flink optimization
Use of SLF4J
Recommended open source tools: MegPeak, a high-performance computing tool
canal scrape data
随机推荐
【Vue.js 3.0源码】KeepAlive 组件:如何让组件在内存中缓存和调度?
内容产品进化三板斧:流量、技术、产品形态
ESP32 Repeated Reboot Issue Arduino Shield Power Outage Detector
MaxWell scraped data
开始学习C语言了
952. 按公因数计算最大组件大小 : 枚举质因数 + 并查集运用题
The use and principle of distributed current limiting reduction RRateLimiter
MongoDB starts an error Process: 29784 ExecStart=/usr/bin/mongod $OPTIONS (code=exited, status=14)
What is the relationship between the construction of smart cities and 5G technology in the new era
学习 MySQL 需要知道的 28 个小技巧
泡沫褪去,DeFi还剩下什么
Flink优化
MongoDB starts an error Process: 29784 ExecStart=/usr/bin/mongod $OPTIONS (code=exited, status=14)
剑指 Offer II 037. 小行星碰撞
Flink real-time data warehouse completed
Machine learning difference in the competition and industry application
[Enlightenment by Opportunity-53]: "Sushu"-3- Self-cultivation and Self-cultivation
CS内网横向移动 模拟渗透实操 超详细
Before quitting, make yourself a roll king
异常情况处置方案