Taking the sample case from https://engineering.pivotal.io/post/go-dep-intro/, if we wanted to specify that we were using the dep-changes branch of github.com/fatih/color, we have two choices:
- manually add a line with branch = "dep-changes" to the entry in Gopkg.toml, followed by a dep ensure to update Gopkg.lock and the vendor directory.
- assuming we weren't already using the package when we did dep init or our most recent dep ensure, then on the command line enter dep ensure -add github.com/fatih/color@dep-changes, ensuring we add the code reference before we execute our next dep ensure.
No comments:
Post a Comment