# Assumes shell is Bash, and pipefail is set.
-bup_t_lib_script_home=$(cd "$(dirname $0)" && pwd)
+bup_t_lib_script_home=$(cd "$(dirname $0)" && pwd) || exit $?
+
+bup-python()
+{
+ "$bup_t_lib_script_home/../cmd/bup-python" "$@"
+}
force-delete()
{
"$bup_t_lib_script_home/force-delete" "$@"
}
-realpath()
+resolve-parent()
{
test "$#" -eq 1 || return $?
echo "$1" | \
- PYTHONPATH="$bup_t_lib_script_home/../lib" python -c \
- "import sys, bup.helpers; print bup.helpers.realpath(sys.stdin.readline())" \
+ PYTHONPATH="$bup_t_lib_script_home/../lib" bup-python -c \
+ "import sys, bup.helpers; print bup.helpers.resolve_parent(sys.stdin.readline())" \
|| return $?
}