]> arthur.barton.de Git - bup.git/blobdiff - cmd/help-cmd.py
Simplify bup startup process
[bup.git] / cmd / help-cmd.py
index 95155b6ad28d8dde6904367e484ffafb0edc086c..4ad5f74d102bfed40764926810fab09d4ec1e32b 100755 (executable)
@@ -4,6 +4,8 @@ bup_python="$(dirname "$0")/bup-python" || exit $?
 exec "$bup_python" "$0" ${1+"$@"}
 """
 # end of bup preamble
+
+from __future__ import absolute_import
 import sys, os, glob
 from bup import options, path
 
@@ -15,7 +17,7 @@ o = options.Options(optspec)
 
 if len(extra) == 0:
     # the wrapper program provides the default usage string
-    os.execvp(os.environ['BUP_MAIN_EXE'], ['bup'])
+    os.execvp(path.exe(), ['bup'])
 elif len(extra) == 1:
     docname = (extra[0]=='bup' and 'bup' or ('bup-%s' % extra[0]))
     manpath = os.path.join(path.exedir(),