Created
October 17, 2014 17:52
-
-
Save tyler-sommer/f692830ab1d1089e6d27 to your computer and use it in GitHub Desktop.
Fix broken gitlab hooks in your project repositories
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Dir.glob('/home/git/repositories/**/*.git') do |item| | |
hook = "#{item}/hooks" | |
if not File.symlink?(hook) | |
puts "Updating #{hook}" | |
File.rename(hook, "#{hook}.old") | |
File.symlink("/home/git/gitlab-shell/hooks", hook) | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment