diff options
author | Richard Dale <richard.dale@codethink.co.uk> | 2013-06-25 09:26:28 +0100 |
---|---|---|
committer | Richard Dale <richard.dale@codethink.co.uk> | 2013-06-25 09:26:28 +0100 |
commit | e15e84e3cab086a8a2301c6c16e34e5a8e07c368 (patch) | |
tree | 99a2d9030d35b94a51ad4eda6c2eb7e147de2f5f /morphlib/app.py | |
parent | 155e5025278d106f3700fa8dffffb4c279dcded0 (diff) | |
download | morph-e15e84e3cab086a8a2301c6c16e34e5a8e07c368.tar.gz |
Don't show git config messages for 'morph branch' in verbose mode
Diffstat (limited to 'morphlib/app.py')
-rw-r--r-- | morphlib/app.py | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/morphlib/app.py b/morphlib/app.py index f82eae33..b8f1eb1e 100644 --- a/morphlib/app.py +++ b/morphlib/app.py @@ -410,6 +410,12 @@ class Morph(cliapp.Application): if 'env' not in kwargs: kwargs['env'] = dict(os.environ) + if 'print_command' in kwargs: + print_command = kwargs['print_command'] + del kwargs['print_command'] + else: + print_command = True + # convert the command line arguments into a string commands = [argv] + list(args) for command in commands: @@ -419,9 +425,10 @@ class Morph(cliapp.Application): commands = [' '.join(command) for command in commands] # print the command line - self.status(msg='# %(cmdline)s', - cmdline=' | '.join(commands), - chatty=True) + if print_command: + self.status(msg='# %(cmdline)s', + cmdline=' | '.join(commands), + chatty=True) # Log the environment. prev = getattr(self, 'prev_env', {}) |