summaryrefslogtreecommitdiff
path: root/lib/tasks
diff options
context:
space:
mode:
authorMicaël Bergeron <mbergeron@gitlab.com>2018-03-22 09:06:10 -0400
committerMicaël Bergeron <mbergeron@gitlab.com>2018-03-22 09:06:10 -0400
commit9c6663ea079128bb730ec2a168b43961cd9462ec (patch)
tree4f62c2e745c7f3e8571ee8c023abcce316c68275 /lib/tasks
parent6801a93e5e7447199b091e44f33c96d22a1a1960 (diff)
parentc01697539c3da4e72b1812662ff35d1f709d1dcc (diff)
downloadgitlab-ce-9c6663ea079128bb730ec2a168b43961cd9462ec.tar.gz
Merge remote-tracking branch 'origin/master' into 40781-os-to-ce
Diffstat (limited to 'lib/tasks')
-rw-r--r--lib/tasks/gitlab/artifacts/check.rake8
-rw-r--r--lib/tasks/gitlab/exclusive_lease.rake9
-rw-r--r--lib/tasks/gitlab/shell.rake2
-rw-r--r--lib/tasks/haml-lint.rake9
4 files changed, 18 insertions, 10 deletions
diff --git a/lib/tasks/gitlab/artifacts/check.rake b/lib/tasks/gitlab/artifacts/check.rake
new file mode 100644
index 00000000000..a105261ed51
--- /dev/null
+++ b/lib/tasks/gitlab/artifacts/check.rake
@@ -0,0 +1,8 @@
+namespace :gitlab do
+ namespace :artifacts do
+ desc 'GitLab | Artifacts | Check integrity of uploaded job artifacts'
+ task check: :environment do
+ Gitlab::Verify::RakeTask.run!(Gitlab::Verify::JobArtifacts)
+ end
+ end
+end
diff --git a/lib/tasks/gitlab/exclusive_lease.rake b/lib/tasks/gitlab/exclusive_lease.rake
new file mode 100644
index 00000000000..83722bf6d94
--- /dev/null
+++ b/lib/tasks/gitlab/exclusive_lease.rake
@@ -0,0 +1,9 @@
+namespace :gitlab do
+ namespace :exclusive_lease do
+ desc 'GitLab | Clear existing exclusive leases for specified scope (default: *)'
+ task :clear, [:scope] => [:environment] do |_, args|
+ args[:scope].nil? ? Gitlab::ExclusiveLease.reset_all! : Gitlab::ExclusiveLease.reset_all!(args[:scope])
+ puts 'All exclusive lease entries were removed.'
+ end
+ end
+end
diff --git a/lib/tasks/gitlab/shell.rake b/lib/tasks/gitlab/shell.rake
index 844664b12d4..4fcbbbf8c9d 100644
--- a/lib/tasks/gitlab/shell.rake
+++ b/lib/tasks/gitlab/shell.rake
@@ -69,7 +69,7 @@ namespace :gitlab do
if File.exist?(path_to_repo)
print '-'
else
- if Gitlab::Shell.new.add_repository(project.repository_storage,
+ if Gitlab::Shell.new.create_repository(project.repository_storage,
project.disk_path)
print '.'
else
diff --git a/lib/tasks/haml-lint.rake b/lib/tasks/haml-lint.rake
index 5c0cc4990fc..ad2d034b0b4 100644
--- a/lib/tasks/haml-lint.rake
+++ b/lib/tasks/haml-lint.rake
@@ -2,14 +2,5 @@ unless Rails.env.production?
require 'haml_lint/rake_task'
require 'haml_lint/inline_javascript'
- # Workaround for warnings from parser/current
- # TODO: Remove this after we update parser gem
- task :haml_lint do
- require 'parser'
- def Parser.warn(*args)
- puts(*args) # static-analysis ignores stdout if status is 0
- end
- end
-
HamlLint::RakeTask.new
end