From: Nix Date: Sat, 19 Jul 2014 22:01:58 +0000 (+0100) Subject: Just log when skipping a large file during save X-Git-Url: https://git.michaelhowe.org/gitweb/?a=commitdiff_plain;h=497505901824dd7382d1d80e152f6b6d810a2844;p=packages%2Fb%2Fbup.git Just log when skipping a large file during save If bup-save --smaller= is specified, the user *expects* large files to be skipped. Having bup report errors and return exitcode 1 in this case hides real errors. Instead, log it when running verbosely, but not otherwise. Signed-off-by: Nick Alcock [rlb@defaultvalue.org: adjust commit summary; simplify opt.verbose >= 1 to opt.verbose] Signed-off-by: Rob Browning Reviewed-by: Rob Browning Tested-by: Rob Browning --- diff --git a/cmd/save-cmd.py b/cmd/save-cmd.py index 8067fac..fce9aad 100755 --- a/cmd/save-cmd.py +++ b/cmd/save-cmd.py @@ -274,7 +274,8 @@ for (transname,ent) in r.filter(extra, wantrecurse=wantrecurse_during): continue if opt.smaller and ent.size >= opt.smaller: if exists and not hashvalid: - add_error('skipping large file "%s"' % ent.name) + if opt.verbose: + log('skipping large file "%s"\n' % ent.name) lastskip_name = ent.name continue