Skip to content
Snippets Groups Projects

Better comment the hooks

Closed Sid Sijbrandij requested to merge better-comment-the-hooks into master
2 files
+ 20
21
Compare changes
  • Side-by-side
  • Inline
Files
2
+ 10
11
@@ -3,8 +3,7 @@
@@ -3,8 +3,7 @@
# This file was placed here by GitLab Shell.
# This file was placed here by GitLab Shell.
# It is a shared file that is symlinked from all repositories.
# It is a shared file that is symlinked from all repositories.
# It makes sure that your pushed commits will be processed properly.
# It makes sure that your pushed commits will be processed properly.
# You can add your own hooks to by uncommenting the lines at the bottom.
# For instructions on how to add custom hooks see the comment below.
# If you upgrade GitLab Shell you will have to redo your changes.
# Consider using project services of post-receive hooks
# Consider using project services of post-receive hooks
# See http://doc.gitlab.com/ce/integration/README.html
# See http://doc.gitlab.com/ce/integration/README.html
# Or use web hooks that trigger an external application
# Or use web hooks that trigger an external application
@@ -17,16 +16,16 @@ repo_path = Dir.pwd
@@ -17,16 +16,16 @@ repo_path = Dir.pwd
require_relative '../lib/gitlab_post_receive'
require_relative '../lib/gitlab_post_receive'
if GitlabPostReceive.new(repo_path, key_id, changes).exec
if GitlabPostReceive.new(repo_path, key_id, changes).exec
 
## How to add a custom hooks to some repositories:
 
## 1) Put a file with custom code in the repository root directory.
 
## 2) Uncomment the lines below.
 
## 3) Replace 'project-specific-hook' with the name if the custom file.
 
## 4) If you upgrade GitLab Shell you will have to redo your changes.
 
#
 
# if File.exists?('project-specific-hook')
 
# execute 'project-specific-hook'
 
# end
exit 0
exit 0
else
else
exit 1
exit 1
end
end
## How to add a custom hooks to some repositories:
## 1) Put a file with custom code in the repository root directory.
## 2) Uncomment the lines below.
## 3) Replace 'project-specific-hook' with the name if the custom file.
#
# if File.exists?('project-specific-hook')
# execute 'project-specific-hook'
# end
Loading