X-Git-Url: https://arthur.barton.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=cmd%2Fdrecurse-cmd.py;h=a3a7d30aa4a368ce682bc55b83c55f0478bb84b2;hb=bf478211a7b79eb5165f62792f1d739492b9311a;hp=cdf66803034bd0f429a869ea75b94ba06f29e25a;hpb=eef7376275bc4bd8672d1295360b4f281ad38c37;p=bup.git diff --git a/cmd/drecurse-cmd.py b/cmd/drecurse-cmd.py index cdf6680..a3a7d30 100755 --- a/cmd/drecurse-cmd.py +++ b/cmd/drecurse-cmd.py @@ -1,8 +1,17 @@ -#!/usr/bin/env python +#!/bin/sh +"""": # -*-python-*- +bup_python="$(dirname "$0")/bup-python" || exit $? +exec "$bup_python" "$0" ${1+"$@"} +""" +# end of bup preamble +from __future__ import absolute_import, print_function from os.path import relpath +import sys + from bup import options, drecurse -from bup.helpers import * +from bup.helpers import log, parse_excludes, parse_rx_excludes, saved_errors + optspec = """ bup drecurse @@ -41,7 +50,7 @@ else: pass else: for (name,st) in it: - print name + print(name) if saved_errors: log('WARNING: %d errors encountered.\n' % len(saved_errors))