summaryrefslogtreecommitdiff
path: root/lib/tasks
diff options
context:
space:
mode:
authorZeger-Jan van de Weg <mail@zjvandeweg.nl>2015-12-07 12:06:20 +0100
committerZeger-Jan van de Weg <mail@zjvandeweg.nl>2015-12-07 12:06:20 +0100
commit3da32ef7d84f5800434379520878fe5c186b9e39 (patch)
tree3095a89ae3a75fca29f3be1b5d2a3d41824a81e1 /lib/tasks
parent113325a9e02b06d9cef82b913e2ab6f33331371b (diff)
parent234f4bf20fb338f2164976fd39203fbc671afd29 (diff)
downloadgitlab-ce-3da32ef7d84f5800434379520878fe5c186b9e39.tar.gz
Merge branch 'master' into rake-tasks-git
Diffstat (limited to 'lib/tasks')
-rw-r--r--lib/tasks/gitlab/task_helpers.rake12
1 files changed, 1 insertions, 11 deletions
diff --git a/lib/tasks/gitlab/task_helpers.rake b/lib/tasks/gitlab/task_helpers.rake
index e35fd47c5c4..ebe516ec879 100644
--- a/lib/tasks/gitlab/task_helpers.rake
+++ b/lib/tasks/gitlab/task_helpers.rake
@@ -2,16 +2,6 @@ module Gitlab
class TaskAbortedByUserError < StandardError; end
end
-unless STDOUT.isatty
- module Colored
- extend self
-
- def colorize(string, options={})
- string
- end
- end
-end
-
namespace :gitlab do
# Ask if the user wants to continue
@@ -103,7 +93,7 @@ namespace :gitlab do
gitlab_user = Gitlab.config.gitlab.user
current_user = run(%W(whoami)).chomp
unless current_user == gitlab_user
- puts "#{Colored.color(:black)+Colored.color(:on_yellow)} Warning #{Colored.extra(:clear)}"
+ puts " Warning ".colorize(:black).on_yellow
puts " You are running as user #{current_user.magenta}, we hope you know what you are doing."
puts " Things may work\/fail for the wrong reasons."
puts " For correct results you should run this as user #{gitlab_user.magenta}."