summaryrefslogtreecommitdiff
path: root/hooks/update
diff options
context:
space:
mode:
authorValery Sizov <valery@gitlab.com>2016-10-03 19:15:14 +0300
committerValery Sizov <valery@gitlab.com>2016-10-05 11:42:25 +0300
commitc0b473418296764764cb716686cd870e7018b242 (patch)
tree2ef6c9418ef1960f782a002bd8f1513b36efda46 /hooks/update
parent0b4fd0af16555b2bdc28f6b18781d72226c5d56c (diff)
downloadgitlab-shell-add_gl_id.tar.gz
added GL_IDadd_gl_id
Diffstat (limited to 'hooks/update')
-rwxr-xr-xhooks/update5
1 files changed, 3 insertions, 2 deletions
diff --git a/hooks/update b/hooks/update
index f1ac8e7..223575d 100755
--- a/hooks/update
+++ b/hooks/update
@@ -3,14 +3,15 @@
# This file was placed here by GitLab. It makes sure that your pushed commits
# will be processed properly.
-ref_name = ARGV[0]
+ref_name = ARGV[0]
old_value = ARGV[1]
new_value = ARGV[2]
repo_path = Dir.pwd
+key_id = ENV.delete('GL_ID')
require_relative '../lib/gitlab_custom_hook'
-if GitlabCustomHook.new.update(ref_name, old_value, new_value, repo_path)
+if GitlabCustomHook.new(key_id).update(ref_name, old_value, new_value, repo_path)
exit 0
else
exit 1