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

Commit

Permalink
Enable vendor/ for go1.7 & Godep workspace -> vendor/
Browse files Browse the repository at this point in the history
go1.7beta1 is out. Time to make sure things work with go1.7+

Once go1.8 is released support for Godep workspaces (./Godeps/_workspace) will be removed.
  • Loading branch information
Edward Muller committed Jun 2, 2016
1 parent f4edf33 commit acd06c8
Show file tree
Hide file tree
Showing 35 changed files with 19 additions and 13 deletions.
6 changes: 6 additions & 0 deletions Changelog.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
#v74 (2016/06/01)

* Enable vendor/ on go1.7
* No longer use a godep workspace, use vendor/ (yay!)
* Notify that support for Godep workspaces will be removed once go1.8 ships

#v73 (2016/05/31)

* Fix permission changes on Windows via @alexbrand. Closes #481.
Expand Down
4 changes: 2 additions & 2 deletions Godeps/Godeps.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 0 additions & 2 deletions Godeps/_workspace/.gitignore

This file was deleted.

2 changes: 1 addition & 1 deletion diff.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"fmt"
"log"

"github.com/tools/godep/Godeps/_workspace/src/github.com/pmezard/go-difflib/difflib"
"github.com/pmezard/go-difflib/difflib"
)

var cmdDiff = &Command{
Expand Down
2 changes: 2 additions & 0 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -77,11 +77,13 @@ func determineVendor(v string) bool {
go15ve := os.Getenv("GO15VENDOREXPERIMENT")
ev := (v == "go1.5" && go15ve == "1") ||
(v == "go1.6" && go15ve != "0") ||
(v == "go1.7") ||
(strings.HasPrefix(v, "devel") && go15ve != "0")

ws := filepath.Join("Godeps", "_workspace")
s, err := os.Stat(ws)
if err == nil && s.IsDir() {
log.Printf("WARNING: Godep workspaces (./Godeps/_workspace) are deprecated and support for them will be removed when go1.8 is released.")
if ev {
log.Printf("WARNING: Go version (%s) & $GO15VENDOREXPERIMENT=%s wants to enable the vendor experiment, but disabling because a Godep workspace (%s) exists\n", v, go15ve, ws)
}
Expand Down
2 changes: 1 addition & 1 deletion msg.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"fmt"
"log"

"github.com/tools/godep/Godeps/_workspace/src/github.com/kr/pretty"
"github.com/kr/pretty"
)

func debugln(a ...interface{}) (int, error) {
Expand Down
2 changes: 1 addition & 1 deletion restore.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
"os"
"path/filepath"

"github.com/tools/godep/Godeps/_workspace/src/golang.org/x/tools/go/vcs"
"golang.org/x/tools/go/vcs"
)

var cmdRestore = &Command{
Expand Down
2 changes: 1 addition & 1 deletion rewrite.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import (
"go/printer"
"go/token"

"github.com/tools/godep/Godeps/_workspace/src/github.com/kr/fs"
"github.com/kr/fs"
)

// rewrite visits the go files in pkgs, plus all go files
Expand Down
2 changes: 1 addition & 1 deletion save.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import (
"regexp"
"strings"

"github.com/tools/godep/Godeps/_workspace/src/github.com/kr/fs"
"github.com/kr/fs"
)

var cmdSave = &Command{
Expand Down
2 changes: 1 addition & 1 deletion vcs.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
"path/filepath"
"strings"

"github.com/tools/godep/Godeps/_workspace/src/golang.org/x/tools/go/vcs"
"golang.org/x/tools/go/vcs"
)

// VCS represents a version control system.
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion ..._workspace/src/github.com/kr/text/wrap.go → vendor/github.com/kr/text/wrap.go
100644 → 100755

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

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 = 73
const version = 74

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

0 comments on commit acd06c8

Please sign in to comment.