X-Git-Url: https://git.distorted.org.uk/~mdw/stgit/blobdiff_plain/ba9c6dc51c6dc0dca67944bf859802389bcaba9b..b4d6a1c5539886c10f4d3965bd62afc793d8e912:/stgit/git.py diff --git a/stgit/git.py b/stgit/git.py index 0e83ffc..984b749 100644 --- a/stgit/git.py +++ b/stgit/git.py @@ -185,10 +185,9 @@ def __tree_status(files = None, tree_id = 'HEAD', unknown = False, noexclude = True, verbose = False): """Returns a list of pairs - [status, filename] """ - if verbose: - print >> sys.stderr, \ - 'Checking for changes in the working directory...', - sys.stderr.flush() + if verbose and sys.stdout.isatty(): + print 'Checking for changes in the working directory...', + sys.stdout.flush() refresh_index() @@ -226,8 +225,8 @@ def __tree_status(files = None, tree_id = 'HEAD', unknown = False, if fs[1] not in conflicts: cache_files.append(fs) - if verbose: - print >> sys.stderr, 'done' + if verbose and sys.stdout.isatty(): + print 'done' return cache_files