Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
tools
godep
Commits
549fe2ce
Commit
549fe2ce
authored
9 years ago
by
Edward Muller
Browse files
Options
Download
Email Patches
Plain Diff
Add docs
parent
fed89a26
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
30 additions
and
0 deletions
+30
-0
Readme.md
Readme.md
+30
-0
No files found.
Readme.md
View file @
549fe2ce
...
...
@@ -128,3 +128,33 @@ Example Godeps:
]
}
```
### Go 1.5 vendor/ experiment
Godep has preliminary support for the Go 1.5 vendor/
[
experiment
](
https://github.com/golang/go/commit/183cc0cd41f06f83cb7a2490a499e3f9101befff
)
utilizing the same environment variable that the go tooling itself supports:
`export GO15VENDOREXPERIMENT=1`
When
`GO15VENDOREXPERIMENT=1`
godep will write the vendored code into the local
package's
`vendor`
directory. A
`Godeps/Godeps.json`
file is created, just like
during normal operation. The vendor experiment is not compatible with rewrites.
There is currently no automated migration between the old Godeps workspace and
the vendor directory, but the following steps should work:
```
term
$ unset GO15VENDOREXPERIMENT
$ godep restore
# The next line is only needed to automatically undo rewritten imports that were
# created with godep save -r.
$ godep save ./...
$ rm -rf Godeps
$ export GO15VENDOREXPERIMENT=1
$ godep save ./...
$ git add -A
# You should see your Godeps/_workspace/src files "moved" to vendor/.
```
NOTE: There is a "bug" in the vendor experiment that makes using
`./...`
with
the go tool (like go install) consider all packages inside the vendor directory:
https://github.com/golang/go/issues/11659.
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment