3 bup_python="$(dirname "$0")/../cmd/bup-python" || exit $?
4 exec "$bup_python" "$0" ${1+"$@"}
8 from __future__ import absolute_import
10 from os.path import getsize, isdir
11 from sys import argv, stderr
14 def listdir_failure(ex):
18 print >> stderr, "Usage: data-size PATH ..."
23 for root, dirs, files in os.walk(path, onerror=listdir_failure):
24 total += sum(getsize(os.path.join(root, name)) for name in files)
26 total += getsize(path)