Skip to content
This repository was archived by the owner on Sep 9, 2020. It is now read-only.

Commit 16990a1

Browse files
authored
Merge pull request #1076 from carolynvs/commit-vendor-faq
Clarify when to run ensure when vendor is not committed
2 parents 6890c50 + 01d6b3a commit 16990a1

File tree

1 file changed

+12
-8
lines changed

1 file changed

+12
-8
lines changed

docs/FAQ.md

+12-8
Original file line numberDiff line numberDiff line change
@@ -116,14 +116,14 @@ authenticated repository.
116116

117117
First, configure `git` to use the credentials option for the specific repository.
118118

119-
For example, if you use gitlab, and you wish to access `https://gitlab.example.com/example/package.git`,
119+
For example, if you use gitlab, and you wish to access `https://gitlab.example.com/example/package.git`,
120120
then you would want to use the following configuration:
121121

122122
```
123123
$ git config --global credential.https://gitlab.example.com.example yourusername
124124
```
125125

126-
In the example the hostname `gitlab.example.com.username` string seems incorrect, but
126+
In the example the hostname `gitlab.example.com.username` string seems incorrect, but
127127
it's actually the hostname plus the name of the repo you are accessing which is `username`.
128128
The trailing 'yourusername' is the username you would use for the actual authentication.
129129

@@ -137,8 +137,8 @@ $ git help -a | grep credential-
137137
credential-osxkeychain remote-ftps
138138
credential-store remote-http
139139
```
140-
141-
You would then choose an appropriate provider. For example, to use the osxkeychain, you
140+
141+
You would then choose an appropriate provider. For example, to use the osxkeychain, you
142142
would use the following:
143143

144144
```
@@ -296,13 +296,17 @@ It's up to you:
296296

297297
**Pros**
298298

299-
- It's the only way to get truly reproducible builds, as it guards against upstream renames, deletes and commit history overwrites.
300-
- You don't need an extra `dep ensure` step (to fetch dependencies) on fresh clones to build your repo: you can use `go get` as usual.
299+
- It's the only way to get truly reproducible builds, as it guards against upstream renames,
300+
deletes and commit history overwrites.
301+
- You don't need an extra `dep ensure` step to sync `vendor/` with Gopkg.lock after most operations,
302+
such as `go get`, cloning, getting latest, merging, etc.
301303

302304
**Cons**
303305

304-
- Your repo will be bigger, potentially a lot bigger.
305-
- PR diffs are more annoying (but files in `vendor/` are [hidden by default](https://github.com/github/linguist/blob/v5.2.0/lib/linguist/generated.rb#L328) on Github).
306+
- Your repo will be bigger, potentially a lot bigger,
307+
though `dep prune` can help minimize this problem.
308+
- PR diffs will include changes for files under `vendor/` when Gopkg.lock is modified,
309+
however files in `vendor/` are [hidden by default](https://github.com/github/linguist/blob/v5.2.0/lib/linguist/generated.rb#L328) on Github.
306310

307311
## How do I roll releases that `dep` will be able to use?
308312

0 commit comments

Comments
 (0)