Permalink
Browse files

fix a couple more output formatting issues

  • Loading branch information...
1 parent c23eda6 commit 95147c3c24f4dd5cbe4e034815e29fbfc95e7002 @lirazsiri lirazsiri committed Nov 7, 2013
Showing with 7 additions and 5 deletions.
  1. +6 −4 backup.py
  2. +1 −1 registry.py
View
@@ -116,7 +116,8 @@ def _write_whatchanged(self, dest, dest_olist, dirindex, dirindex_conf,
file(dest_olist, "w").writelines((path + "\n" for path in olist))
if self.verbose:
- self._log("Save list of filesystem changes to %s:\n" % dest)
+ if changes:
+ self._log("Save list of filesystem changes to %s:\n" % dest)
actions = list(changes.deleted(optimized=False)) + list(changes.statfixes(optimized=False))
actions.sort(lambda a,b: cmp(a.args[0], b.args[0]))
@@ -137,9 +138,10 @@ def _write_whatchanged(self, dest, dest_olist, dirindex, dirindex_conf,
self._log(" " + str(action))
- self._log("\nSave list of new files to %s:\n" % dest_olist)
- for path in olist:
- self._log(" " + path)
+ if olist:
+ self._log("\nSave list of new files to %s:\n" % dest_olist)
+ for path in olist:
+ self._log(" " + path)
def _create_extras(self, extras, profile, conf):
os.mkdir(extras.path)
View
@@ -321,7 +321,7 @@ def update_profile(profile_id=None, strict=True):
global registry
if profile_id == registry.EMPTY_PROFILE:
- print """\
+ print """
Creating an empty profile, which means:
- We only backup files as included or excluded in the override paths specified

0 comments on commit 95147c3

Please sign in to comment.