From 7d9ffa07aca4bfc8e75036c254df8bae9a77f0b2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Mon, 24 Mar 2014 13:46:51 +0100 Subject: [PATCH] Do not print needless newlines in check. --- osclib/check_command.py | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/osclib/check_command.py b/osclib/check_command.py index 3b774ab8..c25e1632 100644 --- a/osclib/check_command.py +++ b/osclib/check_command.py @@ -18,7 +18,7 @@ class CheckCommand(object): # If the project is empty just skip it if not state: - return + return None print('Checking staging project: {}'.format(project)) if type(state) is list: @@ -28,6 +28,8 @@ class CheckCommand(object): else: print(' ++ Acceptable staging project') + return True + def perform(self, project): """ Check one staging project verbosibly or all of them at once @@ -37,8 +39,8 @@ class CheckCommand(object): self._check_one_project(project, True) else: for project in self.api.get_staging_projects(): - self._check_one_project(project, False) - # newline to split multiple prjs at once - print('') + if self._check_one_project(project, False): + # newline to split multiple prjs at once + print('') return True