duanli0162 2014-08-12 15:01
浏览 134
已采纳

用于git pull的Golang工具?

I'm trying to make it easy for the not-too-technical to use my golang program as a command line application. I want them to be able to update the code easily too when I push changes to github. Is there a way to update a library using something like "go update github.com/user/repo" so they don't have to cd to the src directory and git pull themselves? Or at this point must I simply say "time to learn git"?

  • 写回答

1条回答 默认 最新

  • douzhan8395 2014-08-12 15:07
    关注

    You can use:

    go get -u import/path

    The -u flag instructs get to use the network to update the named packages and their dependencies. By default, get uses the network to check out missing packages but does not use it to look for updates to existing packages.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?