1
0
mirror of https://github.com/golang/go synced 2024-11-18 11:04:42 -07:00

cmd/go: fix "go get -u" for git repositories.

CL 10869046 changed cmd/go to checkout master branch, so
for "go get -u" to work, it must "git pull" instead of
"git fetch". Added "--ff-only" so that it won't accidentally
overwrite user changes.

R=dsymonds
CC=golang-dev
https://golang.org/cl/10907043
This commit is contained in:
Shenghou Ma 2013-07-07 23:06:30 +08:00
parent 3c3ce8e7fb
commit 8b16a8bbc1

View File

@ -91,7 +91,7 @@ var vcsGit = &vcsCmd{
cmd: "git",
createCmd: "clone {repo} {dir}",
downloadCmd: "fetch",
downloadCmd: "pull --ff-only",
tagCmd: []tagCmd{
// tags/xxx matches a git tag named xxx