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

gitlab.com/gitlab-org/gitlab-docs.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAchilleas Pipinellis <axilleas@axilleas.me>2016-11-07 23:39:06 +0300
committerConnor Shea <connor.james.shea@gmail.com>2016-11-09 23:20:11 +0300
commit04f25524d1efbb2b1365d6ece8c65fdb00018602 (patch)
tree7bced9426951e1d2915a233c0eaf46e8f52760af /Rakefile
parente124cfe44b289ad32be4e66fc4f8fb3eb655c36b (diff)
Init addition of GitLab Runner
Diffstat (limited to 'Rakefile')
-rw-r--r--Rakefile29
1 files changed, 23 insertions, 6 deletions
diff --git a/Rakefile b/Rakefile
index 289d7253..37721c95 100644
--- a/Rakefile
+++ b/Rakefile
@@ -1,29 +1,39 @@
# By default won't delete any directories, requires all relevant directories
# be empty. Run `RAKE_FORCE_DELETE=true rake pull_repos` to have directories
# deleted.
-desc 'Pulls down the CE, EE, and Omnibus git repos and merges the content of their doc directories into the nanoc site'
+desc 'Pulls down the CE, EE, Omnibus and Runner git repos and merges the content of their doc directories into the nanoc site'
task :pull_repos do
force_delete = ENV['RAKE_FORCE_DELETE']
ce = {
+ name: 'ce',
repo: 'https://gitlab.com/gitlab-org/gitlab-ce.git',
temp_dir: 'tmp/ce/',
dest_dir: 'content/ce'
}
ee = {
+ name: 'ee',
repo: 'https://gitlab.com/gitlab-org/gitlab-ee.git',
temp_dir: 'tmp/ee/',
dest_dir: 'content/ee'
}
omnibus = {
+ name: 'omnibus',
repo: 'https://gitlab.com/gitlab-org/omnibus-gitlab.git',
temp_dir: 'tmp/omnibus/',
dest_dir: 'content/omnibus'
}
- products = [ce, ee, omnibus]
+ runner = {
+ name: 'runner',
+ repo: 'https://gitlab.com/gitlab-org/gitlab-ci-multi-runner.git',
+ temp_dir: 'tmp/runner/',
+ dest_dir: 'content/runner'
+ }
+
+ products = [ce, ee, omnibus, runner]
dirs = []
products.each do |product|
dirs.push(product[:temp_dir])
@@ -45,12 +55,19 @@ task :pull_repos do
"the task will run without manual intervention, run \n" +
"`RAKE_FORCE_DELETE=true rake pull_repos`."
end
-
+
products.each do |product|
puts "\n=> Cloning #{product[:repo]} into #{product[:temp_dir]}\n"
`git clone #{product[:repo]} #{product[:temp_dir]} --depth 1`
-
- puts "\n=> Moving #{product[:temp_dir]}doc/ into #{product[:dest_dir]}\n"
- `mv #{product[:temp_dir]}doc/ #{product[:dest_dir]}`
+
+ # The Runner's docs are stored in docs/ whereas all the other projects
+ # store them in doc/.
+ doc_dir = if product[:name] == 'runner'
+ then 'docs'
+ else 'doc'
+ end
+
+ puts "\n=> Moving #{product[:temp_dir]}#{doc_dir}/ into #{product[:dest_dir]}\n"
+ `mv #{product[:temp_dir]}#{doc_dir}/ #{product[:dest_dir]}`
end
end