Skip to content

Commit 11e8eed

Browse files
author
Konstantin Yegupov
committed
feat: enable fetching manifests for Go vendor and dep package managers.
1 parent 2edd472 commit 11e8eed

File tree

5 files changed

+159
-4
lines changed

5 files changed

+159
-4
lines changed

client-templates/bitbucket-server/accept.json.sample

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -207,6 +207,39 @@
207207
"password": "${BITBUCKET_PASSWORD}"
208208
}
209209
},
210+
{
211+
"//": "used to determine the full dependency tree",
212+
"method": "GET",
213+
"path": "/projects/:project/repos/:repo/browse*/Gopkg.toml",
214+
"origin": "https://${BITBUCKET_API}",
215+
"auth": {
216+
"scheme": "basic",
217+
"username": "${BITBUCKET_USERNAME}",
218+
"password": "${BITBUCKET_PASSWORD}"
219+
}
220+
},
221+
{
222+
"//": "used to determine the full dependency tree",
223+
"method": "GET",
224+
"path": "/projects/:project/repos/:repo/browse*/Gopkg.lock",
225+
"origin": "https://${BITBUCKET_API}",
226+
"auth": {
227+
"scheme": "basic",
228+
"username": "${BITBUCKET_USERNAME}",
229+
"password": "${BITBUCKET_PASSWORD}"
230+
}
231+
},
232+
{
233+
"//": "used to determine the full dependency tree",
234+
"method": "GET",
235+
"path": "/projects/:project/repos/:repo/browse*/vendor/vendor.json",
236+
"origin": "https://${BITBUCKET_API}",
237+
"auth": {
238+
"scheme": "basic",
239+
"username": "${BITBUCKET_USERNAME}",
240+
"password": "${BITBUCKET_PASSWORD}"
241+
}
242+
},
210243
{
211244
"//": "used to check if there's any ignore rules or existing patches",
212245
"method": "GET",

client-templates/github-com/accept.json.sample

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,30 @@
122122
{
123123
"path": "commits.*.modified.*",
124124
"value": "project.json"
125+
},
126+
{
127+
"path": "commits.*.added.*",
128+
"value": "Gopkg.toml"
129+
},
130+
{
131+
"path": "commits.*.modified.*",
132+
"value": "Gopkg.toml"
133+
},
134+
{
135+
"path": "commits.*.added.*",
136+
"value": "Gopkg.lock"
137+
},
138+
{
139+
"path": "commits.*.modified.*",
140+
"value": "Gopkg.lock"
141+
},
142+
{
143+
"path": "commits.*.added.*",
144+
"value": "vendor.json"
145+
},
146+
{
147+
"path": "commits.*.modified.*",
148+
"value": "vendor.json"
125149
}
126150
]
127151
},
@@ -427,6 +451,42 @@
427451
"path": "/:name/:repo/:path*/project.json",
428452
"origin": "https://${GITHUB_TOKEN}@${GITHUB_RAW}"
429453
},
454+
{
455+
"//": "used to determine the full dependency tree",
456+
"method": "GET",
457+
"path": "/repos/:name/:repo/contents/:path*/Gopkg.toml",
458+
"origin": "https://${GITHUB_TOKEN}@${GITHUB_API}"
459+
},
460+
{
461+
"//": "used to determine the full dependency tree",
462+
"method": "GET",
463+
"path": "/:name/:repo/:path*/Gopkg.toml",
464+
"origin": "https://${GITHUB_TOKEN}@${GITHUB_RAW}"
465+
},
466+
{
467+
"//": "used to determine the full dependency tree",
468+
"method": "GET",
469+
"path": "/repos/:name/:repo/contents/:path*/Gopkg.lock",
470+
"origin": "https://${GITHUB_TOKEN}@${GITHUB_API}"
471+
},
472+
{
473+
"//": "used to determine the full dependency tree",
474+
"method": "GET",
475+
"path": "/:name/:repo/:path*/Gopkg.lock",
476+
"origin": "https://${GITHUB_TOKEN}@${GITHUB_RAW}"
477+
},
478+
{
479+
"//": "used to determine the full dependency tree",
480+
"method": "GET",
481+
"path": "/repos/:name/:repo/contents/:path*/vendor.json",
482+
"origin": "https://${GITHUB_TOKEN}@${GITHUB_API}"
483+
},
484+
{
485+
"//": "used to determine the full dependency tree",
486+
"method": "GET",
487+
"path": "/:name/:repo/:path*/vendor.json",
488+
"origin": "https://${GITHUB_TOKEN}@${GITHUB_RAW}"
489+
},
430490
{
431491
"//": "used to check if there's any ignore rules or existing patches",
432492
"method": "GET",

client-templates/github-enterprise/accept.json.sample

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,31 @@
122122
{
123123
"path": "commits.*.modified.*",
124124
"value": "project.json"
125+
},
126+
{
127+
"path": "commits.*.added.*",
128+
"value": "Gopkg.toml"
129+
},
130+
{
131+
"path": "commits.*.modified.*",
132+
"value": "Gopkg.toml"
133+
},
134+
{
135+
"path": "commits.*.added.*",
136+
137+
"value": "Gopkg.lock"
138+
},
139+
{
140+
"path": "commits.*.modified.*",
141+
"value": "Gopkg.lock"
142+
},
143+
{
144+
"path": "commits.*.added.*",
145+
"value": "vendor.json"
146+
},
147+
{
148+
"path": "commits.*.modified.*",
149+
"value": "vendor.json"
125150
}
126151
]
127152
},
@@ -343,6 +368,24 @@
343368
"path": "/repos/:name/:repo/contents/:path*/project.json",
344369
"origin": "https://${GITHUB_TOKEN}@${GITHUB_API}"
345370
},
371+
{
372+
"//": "used to determine the full dependency tree",
373+
"method": "GET",
374+
"path": "/repos/:name/:repo/contents/:path*/Gopkg.toml",
375+
"origin": "https://${GITHUB_TOKEN}@${GITHUB_API}"
376+
},
377+
{
378+
"//": "used to determine the full dependency tree",
379+
"method": "GET",
380+
"path": "/repos/:name/:repo/contents/:path*/Gopkg.lock",
381+
"origin": "https://${GITHUB_TOKEN}@${GITHUB_API}"
382+
},
383+
{
384+
"//": "used to determine the full dependency tree",
385+
"method": "GET",
386+
"path": "/repos/:name/:repo/contents/:path*/vendor/vendor.json",
387+
"origin": "https://${GITHUB_TOKEN}@${GITHUB_API}"
388+
},
346389
{
347390
"//": "used to check if there's any ignore rules or existing patches",
348391
"method": "GET",

client-templates/gitlab/accept.json.sample

Lines changed: 22 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,24 @@
129129
"path": "/api/v4/projects/:project/repository/files*/project.json",
130130
"origin": "https://${GITLAB}"
131131
},
132+
{
133+
"//": "used to determine the full dependency tree",
134+
"method": "GET",
135+
"path": "/api/v4/projects/:project/repository/files*/Gopkg.toml",
136+
"origin": "https://${GITLAB}"
137+
},
138+
{
139+
"//": "used to determine the full dependency tree",
140+
"method": "GET",
141+
"path": "/api/v4/projects/:project/repository/files*/Gopkg.lock",
142+
"origin": "https://${GITLAB}"
143+
},
144+
{
145+
"//": "used to determine the full dependency tree",
146+
"method": "GET",
147+
"path": "/api/v4/projects/:project/repository/files*/vendor.json",
148+
"origin": "https://${GITLAB}"
149+
},
132150
{
133151
"//": "used to check if there's any ignore rules or existing patches",
134152
"method": "GET",
@@ -158,7 +176,10 @@
158176
"**/*.csproj",
159177
"**/*.vbproj",
160178
"**/*.fsproj",
161-
"**/project.json"
179+
"**/project.json",
180+
"**/Gopkg.toml",
181+
"**/Gopkg.lock",
182+
"**/vendor.json"
162183
]
163184
}
164185
]

package-lock.json

Lines changed: 1 addition & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)