Skip to content

Commit

Permalink
Fix colored output in newline
Browse files Browse the repository at this point in the history
Fix ts (moreutils) is used the nextline had the color from the previous one
  • Loading branch information
mblaschke committed Dec 14, 2016
1 parent 751beda commit 1f4235c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions bin/webdevops/doit/DoitReporter.py
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ def add_failure(self, task, exception):

if task.actions and (task.name[0] != '_'):
duration = self.duration(self.t_results[task.name].elapsed)
self.write(colored('. %s FAILED (%s)\n' % (BaseTaskLoader.human_task_name(task.title()), duration), 'red'))
self.writeln(colored('. %s FAILED (%s)' % (BaseTaskLoader.human_task_name(task.title()), duration), 'red'))
self.failures.append({'task': task, 'exception': exception})

def add_success(self, task):
Expand All @@ -149,7 +149,7 @@ def add_success(self, task):

if task.actions and (task.name[0] != '_'):
duration = self.duration(self.t_results[task.name].elapsed)
self.write(colored('. %s finished (%s)\n' % (BaseTaskLoader.human_task_name(task.title()), duration), 'green'))
self.writeln(colored('. %s finished (%s)' % (BaseTaskLoader.human_task_name(task.title()), duration), 'green'))

def skip_uptodate(self, task):
"""
Expand Down

0 comments on commit 1f4235c

Please sign in to comment.