git clone 與 go get


go下載包兩種命令:

go get 目錄

git clone https://+目錄

 

有時候會報錯說remote:Not Found

就把目錄別寫的那么深,或者后面加上個.git即可

 

例如,我想下載github.com/opentracing-contrib/go-stdlib/nethttp

我嘗試了下面這些:

git clone https://github.com/opentracing-contrib/go-stdlib/nethttp

git clone https://github.com/opentracing-contrib/go-stdlib

git clone https://github.com/opentracing-contrib

git clone https://github.com/opentracing-contrib/go-stdlib/nethttp.git

結果都說不存在romote:Not Found,直到試到下面這個,才下載出來了:

git clone https://github.com/opentracing-contrib/go-stdlib.git

這里就提供了一種當報錯remote:Not Found該怎么辦的一種解決辦法,僅供參考。

 

注意切換到哪個目錄 寫命令git clone ,就下載到哪里

E:\Go\src\mtauth\vendor\github.com> 比如我切換到到這里寫git clone 命令,就下載到這個路徑下了

 

That's all

 


免責聲明!

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



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