]> arthur.barton.de Git - bup.git/blobdiff - cmd/save-cmd.py
cleanup-mounts-under: Don't fail when /proc/mounts isn't readable
[bup.git] / cmd / save-cmd.py
index 8067facb872c38ffb40832d7442b7a81f3b43436..b8e4f7aa597d999d877a31a40b36f4c40e205a71 100755 (executable)
@@ -74,7 +74,11 @@ if opt.name and opt.name.startswith('.'):
     o.fatal("'%s' is not a valid branch name" % opt.name)
 refname = opt.name and 'refs/heads/%s' % opt.name or None
 if opt.remote or is_reverse:
-    cli = client.Client(opt.remote)
+    try:
+        cli = client.Client(opt.remote)
+    except client.ClientError, e:
+        log('error: %s' % e)
+        sys.exit(1)
     oldref = refname and cli.read_ref(refname) or None
     w = cli.new_packwriter(compression_level=opt.compress)
 else:
@@ -274,7 +278,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