Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-05-14 18:08:14 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2020-05-14 18:08:14 +0300
commit87f286558de1f5790b0b1742f10548387b5d147a (patch)
treec483d5f3542094d2123c8116ffee22430d9ad9c9 /lib/gitlab/task_helpers.rb
parent674e7e2c3d295704bdf504dd0caa2e5a2d9b5cd2 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'lib/gitlab/task_helpers.rb')
-rw-r--r--lib/gitlab/task_helpers.rb8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/gitlab/task_helpers.rb b/lib/gitlab/task_helpers.rb
index ac02ec635e4..6ccb442b1e0 100644
--- a/lib/gitlab/task_helpers.rb
+++ b/lib/gitlab/task_helpers.rb
@@ -157,8 +157,8 @@ module Gitlab
Rails.env.test? ? Rails.root.join('tmp/tests') : Gitlab.config.gitlab.user_home
end
- def checkout_or_clone_version(version:, repo:, target_dir:)
- clone_repo(repo, target_dir) unless Dir.exist?(target_dir)
+ def checkout_or_clone_version(version:, repo:, target_dir:, clone_opts: [])
+ clone_repo(repo, target_dir, clone_opts: clone_opts) unless Dir.exist?(target_dir)
checkout_version(get_version(version), target_dir)
end
@@ -171,8 +171,8 @@ module Gitlab
"v#{component_version}"
end
- def clone_repo(repo, target_dir)
- run_command!(%W[#{Gitlab.config.git.bin_path} clone -- #{repo} #{target_dir}])
+ def clone_repo(repo, target_dir, clone_opts: [])
+ run_command!(%W[#{Gitlab.config.git.bin_path} clone] + clone_opts + %W[-- #{repo} #{target_dir}])
end
def checkout_version(version, target_dir)