diff options
author | Douwe Maan <douwe@selenight.nl> | 2017-02-22 21:18:40 +0300 |
---|---|---|
committer | Douwe Maan <douwe@selenight.nl> | 2017-02-23 18:32:42 +0300 |
commit | 87c9df29ce8835da5d68dbf3e59674bd4524ee96 (patch) | |
tree | 0db8fb3fdda766f312441729d003b68ced7b2fa5 /lib/tasks/gitlab/sidekiq.rake | |
parent | e2bbbb1a9aea72e4313cdc257460eb416fe8dc0b (diff) |
Don’t exclude some file in lib from rubocop
Diffstat (limited to 'lib/tasks/gitlab/sidekiq.rake')
-rw-r--r-- | lib/tasks/gitlab/sidekiq.rake | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/tasks/gitlab/sidekiq.rake b/lib/tasks/gitlab/sidekiq.rake index f2e12d85045..6cbc83b8973 100644 --- a/lib/tasks/gitlab/sidekiq.rake +++ b/lib/tasks/gitlab/sidekiq.rake @@ -1,9 +1,9 @@ namespace :gitlab do namespace :sidekiq do - QUEUE = 'queue:post_receive' + QUEUE = 'queue:post_receive'.freeze desc 'Drop all Sidekiq PostReceive jobs for a given project' - task :drop_post_receive , [:project] => :environment do |t, args| + task :drop_post_receive, [:project] => :environment do |t, args| unless args.project.present? abort "Please specify the project you want to drop PostReceive jobs for:\n rake gitlab:sidekiq:drop_post_receive[group/project]" end @@ -21,7 +21,7 @@ namespace :gitlab do # new jobs already. We will repopulate it with the old jobs, skipping the # ones we want to drop. dropped = 0 - while (job = redis.lpop(temp_queue)) do + while (job = redis.lpop(temp_queue)) if repo_path(job) == project_path dropped += 1 else |