Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitaly.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJacob Vosmaer <jacob@gitlab.com>2018-08-17 14:41:22 +0300
committerZeger-Jan van de Weg <zegerjan@gitlab.com>2018-08-17 14:41:22 +0300
commit104532b41534a3498711bcc0a210c81e3c4f6348 (patch)
tree1200c49ef5fa5bd26f66107e1d4b9d8ee57eb37d /_support
parent7b334395c9cd6a6257a5d93c00e365d326531bc0 (diff)
Add vendor-gitaly-proto script
Diffstat (limited to '_support')
-rwxr-xr-x_support/vendor-gitaly-proto16
1 files changed, 16 insertions, 0 deletions
diff --git a/_support/vendor-gitaly-proto b/_support/vendor-gitaly-proto
new file mode 100755
index 000000000..fc4c36f51
--- /dev/null
+++ b/_support/vendor-gitaly-proto
@@ -0,0 +1,16 @@
+#!/usr/bin/env ruby
+require 'optparse'
+require_relative 'run'
+
+PROGNAME = 'vendor-gitaly-proto'
+USAGE = "Usage: #{PROGNAME} [--fork GITALY_PROTO_FORK_REPO] REVISION"
+ORIGIN = 'gitlab.com/gitlab-org/gitaly-proto'
+
+def main(revision, repo:)
+ run!(%W[govendor fetch #{ORIGIN}/go::#{repo}/go@#{revision}])
+end
+
+options = ARGV.getopts(nil, 'fork:')
+abort USAGE unless ARGV.count == 1
+
+main(ARGV.first, repo: options['fork'] || ORIGIN)