Commit 4157d523 authored by Valery Sizov's avatar Valery Sizov

Revert "Restore hooks PATH before calling ruby."

This reverts commit cd9e7963.
parent b7a1a252
v2.3.0
- Restore PATH before calling hooks
v2.2.0 v2.2.0
- Support for custom hooks (Drew Blessing and Jose Kahan) - Support for custom hooks (Drew Blessing and Jose Kahan)
......
#!/usr/bin/env bash #!/usr/bin/env ruby
# Remove paths Git automatically prepends to PATH on hooks. # This file was placed here by GitLab. It makes sure that your pushed commits
export PATH="$GITLAB_PATH_OUTSIDE_HOOK" # will be processed properly.
ruby "$GIT_DIR/hooks/post-receive-main.rb"
refs = ARGF.read
key_id = ENV['GL_ID']
repo_path = Dir.pwd
require_relative '../lib/gitlab_custom_hook'
require_relative '../lib/gitlab_post_receive'
if GitlabPostReceive.new(repo_path, key_id, refs).exec &&
GitlabCustomHook.new.post_receive(refs, repo_path)
exit 0
else
exit 1
end
#!/usr/bin/env ruby
# This file was placed here by GitLab. It makes sure that your pushed commits
# will be processed properly.
refs = ARGF.read
key_id = ENV['GL_ID']
repo_path = Dir.pwd
require_relative '../lib/gitlab_custom_hook'
require_relative '../lib/gitlab_post_receive'
if GitlabPostReceive.new(repo_path, key_id, refs).exec &&
GitlabCustomHook.new.post_receive(refs, repo_path)
exit 0
else
exit 1
end
#!/usr/bin/env bash #!/usr/bin/env ruby
# Remove paths Git automatically prepends to PATH on hooks. # This file was placed here by GitLab. It makes sure that your pushed commits
export PATH="$GITLAB_PATH_OUTSIDE_HOOK" # will be processed properly.
ruby "$GIT_DIR/hooks/pre-receive-main.rb"
refs = ARGF.read
key_id = ENV['GL_ID']
repo_path = Dir.pwd
require_relative '../lib/gitlab_custom_hook'
require_relative '../lib/gitlab_access'
if GitlabAccess.new(repo_path, key_id, refs).exec &&
GitlabCustomHook.new.pre_receive(refs, repo_path)
exit 0
else
exit 1
end
#!/usr/bin/env ruby
# This file was placed here by GitLab. It makes sure that your pushed commits
# will be processed properly.
refs = ARGF.read
key_id = ENV['GL_ID']
repo_path = Dir.pwd
require_relative '../lib/gitlab_custom_hook'
require_relative '../lib/gitlab_access'
if GitlabAccess.new(repo_path, key_id, refs).exec &&
GitlabCustomHook.new.pre_receive(refs, repo_path)
exit 0
else
exit 1
end
#!/usr/bin/env bash #!/usr/bin/env ruby
# Remove paths Git automatically prepends to PATH on hooks. # This file was placed here by GitLab. It makes sure that your pushed commits
export PATH="$GITLAB_PATH_OUTSIDE_HOOK" # will be processed properly.
ruby "$GIT_DIR/hooks/update-main.rb"
ref_name = ARGV[0]
old_value = ARGV[1]
new_value = ARGV[2]
repo_path = Dir.pwd
require_relative '../lib/gitlab_custom_hook'
if GitlabCustomHook.new.update(ref_name, old_value, new_value, repo_path)
exit 0
else
exit 1
end
#!/usr/bin/env ruby
# This file was placed here by GitLab. It makes sure that your pushed commits
# will be processed properly.
ref_name = ARGV[0]
old_value = ARGV[1]
new_value = ARGV[2]
repo_path = Dir.pwd
require_relative '../lib/gitlab_custom_hook'
if GitlabCustomHook.new.update(ref_name, old_value, new_value, repo_path)
exit 0
else
exit 1
end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment