2013-02-18 17:03:29 +01:00
|
|
|
root = Gitlab.config.gitlab_shell.repos_path
|
2012-11-13 21:11:56 +01:00
|
|
|
|
|
|
|
projects = [
|
2012-12-27 04:14:05 +01:00
|
|
|
{ path: 'underscore.git', git: 'https://github.com/documentcloud/underscore.git' },
|
|
|
|
{ path: 'diaspora.git', git: 'https://github.com/diaspora/diaspora.git' },
|
2012-12-11 12:44:36 +01:00
|
|
|
{ path: 'brightbox/brightbox-cli.git', git: 'https://github.com/brightbox/brightbox-cli.git' },
|
2012-12-27 04:14:05 +01:00
|
|
|
{ path: 'brightbox/puppet.git', git: 'https://github.com/brightbox/puppet.git' },
|
|
|
|
{ path: 'gitlab/gitlabhq.git', git: 'https://github.com/gitlabhq/gitlabhq.git' },
|
|
|
|
{ path: 'gitlab/gitlab-ci.git', git: 'https://github.com/gitlabhq/gitlab-ci.git' },
|
2013-01-04 17:43:41 +01:00
|
|
|
{ path: 'gitlab/gitlab-recipes.git', git: 'https://github.com/gitlabhq/gitlab-recipes.git' },
|
2012-11-13 21:11:56 +01:00
|
|
|
]
|
|
|
|
|
|
|
|
projects.each do |project|
|
|
|
|
project_path = File.join(root, project[:path])
|
|
|
|
|
2013-02-09 14:13:56 +01:00
|
|
|
if File.exists?(project_path)
|
|
|
|
print '-'
|
|
|
|
next
|
|
|
|
end
|
2012-11-13 21:11:56 +01:00
|
|
|
|
2013-02-09 14:13:56 +01:00
|
|
|
if system("/home/git/gitlab-shell/bin/gitlab-projects import-project #{project[:path]} #{project[:git]}")
|
|
|
|
print '.'
|
|
|
|
else
|
|
|
|
print 'F'
|
2012-11-13 21:11:56 +01:00
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
puts "OK".green
|
2013-02-09 14:13:56 +01:00
|
|
|
|