This repository was archived by the owner on Sep 9, 2020. It is now read-only.
File tree 1 file changed +14
-0
lines changed
1 file changed +14
-0
lines changed Original file line number Diff line number Diff line change @@ -16,6 +16,7 @@ Summarize the question and quote the reply, linking back to the original comment
16
16
* [ How do I constrain a transitive dependency's version?] ( #how-do-i-constrain-a-transitive-dependencys-version )
17
17
* [ Can I put the manifest and lock in the vendor directory?] ( #can-i-put-the-manifest-and-lock-in-the-vendor-directory )
18
18
* [ How do I get ` dep ` to authenticate to a ` git ` repo?] ( #how-do-i-get-dep-to-authenticate-to-a-git-repo )
19
+ * [ How do I get ` dep ` to consume private ` git ` repos using a Github Token?] ( #how-do-i-get-dep-to-consume-private-git-repos-using-a-github-token )
19
20
20
21
## Behavior
21
22
* [ How does ` dep ` decide what version of a dependency to use?] ( #how-does-dep-decide-what-version-of-a-dependency-to-use )
@@ -152,6 +153,19 @@ After configuring `git`, you may need to use `git` manually once to have it stor
152
153
credentials. Once you've checked out the repo manually, it will then use the stored
153
154
credentials. This at least appears to be the behavior for the osxkeychain provider.
154
155
156
+ ### How do I get dep to consume private git repos using a Github Token?
157
+
158
+ Another alternative to make ` dep ` work with private repos is to use a [ Personal Github
159
+ Token] ( https://help.github.com/articles/creating-a-personal-access-token-for-the-command-line/ )
160
+ and configure it inside the [ ` .netrc ` file] ( https://www.gnu.org/software/inetutils/manual/html_node/The-_002enetrc-file.html )
161
+ as the following example:
162
+ ```
163
+ machine github.com
164
+ login [YOUR_GITHUB_TOKEN]
165
+ ```
166
+
167
+ Once you have set that up, dep will automatically use that Token to authenticate to the repositories.
168
+
155
169
## Behavior
156
170
### How does ` dep ` decide what version of a dependency to use?
157
171
You can’t perform that action at this time.
0 commit comments