diff options
-rw-r--r-- | CHANGELOG | 3 | ||||
-rwxr-xr-x | hooks/pre-receive | 4 |
2 files changed, 5 insertions, 2 deletions
@@ -1,3 +1,6 @@ +v5.9.2 + - Fix pre-receive error when gitlab doesn't have /internal/pre_receive (!169) + v5.9.1 - Adds --force option to push branches diff --git a/hooks/pre-receive b/hooks/pre-receive index 78ff991..d7fecc7 100755 --- a/hooks/pre-receive +++ b/hooks/pre-receive @@ -9,7 +9,7 @@ protocol = ENV.delete('GL_PROTOCOL') repo_path = Dir.pwd gl_repository = ENV['GL_REPOSITORY'] -def increase_reference_counter(gl_repository) +def increase_reference_counter(gl_repository, repo_path) result = GitlabNet.new.pre_receive(gl_repository) result['reference_counter_increased'] @@ -28,7 +28,7 @@ require_relative '../lib/gitlab_net' # and we don't want to skip it if the custom hook fails. if GitlabAccess.new(gl_repository, repo_path, key_id, refs, protocol).exec && GitlabCustomHook.new(repo_path, key_id).pre_receive(refs) && - increase_reference_counter(gl_repository) + increase_reference_counter(gl_repository, repo_path) exit 0 else exit 1 |