Commit 562a461c56334bbf466ed1c42e3fc9650207c62f
1 parent
44c55307
Exists in
master
and in
4 other branches
Disable rake color output unless connected to TTY
Showing
1 changed file
with
10 additions
and
0 deletions
Show diff stats
lib/tasks/gitlab/task_helpers.rake
| ... | ... | @@ -2,6 +2,16 @@ module Gitlab |
| 2 | 2 | class TaskAbortedByUserError < StandardError; end |
| 3 | 3 | end |
| 4 | 4 | |
| 5 | +unless STDOUT.isatty | |
| 6 | + module Colored | |
| 7 | + extend self | |
| 8 | + | |
| 9 | + def colorize(string, options={}) | |
| 10 | + string | |
| 11 | + end | |
| 12 | + end | |
| 13 | +end | |
| 14 | + | |
| 5 | 15 | namespace :gitlab do |
| 6 | 16 | |
| 7 | 17 | # Ask if the user wants to continue | ... | ... |