diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2013-02-11 09:15:42 +0200 |
---|---|---|
committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2013-02-11 09:15:42 +0200 |
commit | fcfb6d8438c5a728a0ea6f026f9b1297c3ec3a1a (patch) | |
tree | ca0e0f94550991f1511bd9761c17def723fc76bc /app/models/repository.rb | |
parent | a404c43805cf6256f80dad6247a16db257a42d17 (diff) | |
download | gitlab-ce-fcfb6d8438c5a728a0ea6f026f9b1297c3ec3a1a.tar.gz |
Since gitlab-shell no sense to check hooks
Diffstat (limited to 'app/models/repository.rb')
-rw-r--r-- | app/models/repository.rb | 19 |
1 files changed, 0 insertions, 19 deletions
diff --git a/app/models/repository.rb b/app/models/repository.rb index 6bfdf2255f2..6d490980764 100644 --- a/app/models/repository.rb +++ b/app/models/repository.rb @@ -60,25 +60,6 @@ class Repository Commit.commits_between(repo, from, to) end - def has_post_receive_file? - !!hook_file - end - - def valid_post_receive_file? - valid_hook_file == hook_file - end - - def valid_hook_file - @valid_hook_file ||= File.read(Rails.root.join('lib', 'hooks', 'post-receive')) - end - - def hook_file - @hook_file ||= begin - hook_path = File.join(path_to_repo, 'hooks', 'post-receive') - File.read(hook_path) if File.exists?(hook_path) - end - end - # Returns an Array of branch names def branch_names repo.branches.collect(&:name).sort |