Skip to content
This repository has been archived by the owner on Feb 26, 2019. It is now read-only.

Commit

Permalink
Note new go1.6+ behavior of not checking out master
Browse files Browse the repository at this point in the history
This is very annoying, but I guess I had my time to complain and didn't.
  • Loading branch information
Edward Muller committed Apr 7, 2016
1 parent 35ee059 commit 584a3f5
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 8 deletions.
4 changes: 4 additions & 0 deletions Changelog.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
#v62 (2016/04/07)

* Note new go1.6+ behavior of not checking out master in README / restore help text.

#v61 (2016/04/06)

* Obey go version build tags based on recorded major go version. Fixes #448.
Expand Down
17 changes: 10 additions & 7 deletions Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,10 @@ time** you run a Go-related command, you wrap it in one of these two ways:
### Restore

The `godep restore` command is the opposite of `godep save`. It will install the
package versions specified in `Godeps/Godeps.json` to your `$GOPATH`. This modifies the state of packages in your `$GOPATH`.
package versions specified in `Godeps/Godeps.json` to your `$GOPATH`. This
modifies the state of packages in your `$GOPATH`. NOTE: `godep restore` leaves
git repositories in a detached state. `go1.6`+ no longer checks out the master
branch when doing a `go get`, see [here](https://github.com/golang/go/commit/42206598671a44111c8f726ad33dc7b265bdf669).

### Edit-test Cycle

Expand Down Expand Up @@ -144,16 +147,16 @@ Example Godeps:

Godep supports the Go 1.5+ vendor/
[experiment](https://github.com/golang/go/commit/183cc0cd41f06f83cb7a2490a499e3f9101befff)
utilizing the same environment variable that the go tooling itself supports
utilizing the same environment variable that the go tooling itself supports
(`GO15VENDOREXPERIMENT`).

godep mostly works the same way as the `go` command line tool. If you have go
1.5.X and set `GO15VENDOREXPERIMENT=1` or have go1.6.X (or devel) `vendor/`
godep mostly works the same way as the `go` command line tool. If you have go
1.5.X and set `GO15VENDOREXPERIMENT=1` or have go1.6.X (or devel) `vendor/`
is enabled. **Unless** you already have a `Godeps/_workspace`. This is a safety
feature and godep warns you about this.
feature and godep warns you about this.

When `vendor/` is enabled godep will write the vendored code into the top level
`./vendor/` directory. A `./Godeps/Godeps.json` file is created to track
`./vendor/` directory. A `./Godeps/Godeps.json` file is created to track
the dependencies and revisions. `vendor/` is not compatible with rewrites.

There is currently no automated migration between the old Godeps workspace and
Expand All @@ -176,7 +179,7 @@ $ rm -rf Godeps
# If on go1.5.X to enable `vendor/`
$ export GO15VENDOREXPERIMENT=1
# re-analyze deps and save to `vendor/`.
# re-analyze deps and save to `vendor/`.
$ godep save <pkg spec>
# Add the changes to your VCS
Expand Down
4 changes: 4 additions & 0 deletions restore.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@ var cmdRestore = &Command{
Long: `
Restore checks out the Godeps-specified version of each package in GOPATH.
NOTE: restore leaves git repositories in a detached state. go1.6+ no longer
checks out the master branch when doing a "go get", see:
https://github.com/golang/go/commit/42206598671a44111c8f726ad33dc7b265bdf669.
`,
Run: runRestore,
OnlyInGOPATH: true,
Expand Down
2 changes: 1 addition & 1 deletion version.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
"strings"
)

const version = 61
const version = 62

var cmdVersion = &Command{
Name: "version",
Expand Down

0 comments on commit 584a3f5

Please sign in to comment.