從GitLab使用go get


使用私有倉庫gitlab進行go依賴管理(go mod / go get)

// 編輯git配置文件 ~/.gitconfig
[url "git@gitlab.***.com:"]
    insteadOf = https://gitlab.***.com   

// 配置環境變量
GOPRIVATE=gitlab.***.com

// gitlab普通版本只能get2層
// 注意 common為gitlab的群組
gitlab.***.com/common/config  //稱之為2層

// config 包的go.mod注意module名字
module gitlab.***.com/common/config


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM