Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kazuhiko Shiozaki
gitlab-ce
Commits
4c68d238
Commit
4c68d238
authored
Jul 07, 2014
by
Marin Jankovski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add sanitize option to gitlab check rake task.
parent
d5a8f9cc
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
26 additions
and
3 deletions
+26
-3
lib/tasks/gitlab/check.rake
lib/tasks/gitlab/check.rake
+26
-3
No files found.
lib/tasks/gitlab/check.rake
View file @
4c68d238
...
...
@@ -216,7 +216,12 @@ namespace :gitlab do
puts
""
Project
.
find_each
(
batch_size:
100
)
do
|
project
|
print
"
#{
project
.
name_with_namespace
.
yellow
}
... "
message
=
if
sanitize
"
#{
project
.
namespace_id
.
to_s
.
yellow
}
/
#{
project
.
id
.
to_s
.
yellow
}
... "
else
"
#{
project
.
name_with_namespace
.
yellow
}
... "
end
print
message
if
project
.
satellite
.
exists?
puts
"yes"
.
green
...
...
@@ -525,7 +530,12 @@ namespace :gitlab do
puts
""
Project
.
find_each
(
batch_size:
100
)
do
|
project
|
print
"
#{
project
.
name_with_namespace
.
yellow
}
... "
message
=
if
sanitize
"
#{
project
.
id
.
to_s
.
yellow
}
... "
else
"
#{
project
.
name_with_namespace
.
yellow
}
... "
end
print
message
if
project
.
empty_repo?
puts
"repository is empty"
.
magenta
...
...
@@ -588,7 +598,12 @@ namespace :gitlab do
puts
""
Project
.
find_each
(
batch_size:
100
)
do
|
project
|
print
"
#{
project
.
name_with_namespace
.
yellow
}
... "
message
=
if
sanitize
"
#{
project
.
namespace_id
.
to_s
.
yellow
}
/
#{
project
.
id
.
to_s
.
yellow
}
... "
else
"
#{
project
.
name_with_namespace
.
yellow
}
... "
end
print
message
if
project
.
namespace
puts
"yes"
.
green
...
...
@@ -837,4 +852,12 @@ namespace :gitlab do
def
omnibus_gitlab?
Dir
.
pwd
==
'/opt/gitlab/embedded/service/gitlab-rails'
end
def
sanitize
if
ENV
[
'SANITIZE'
]
==
"true"
true
else
false
end
end
end
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment