-#!/usr/bin/env python
-
-# This cannot rely on bup-python because it runs during clean, and so
-# it also needs to be compatible with Python 2 and 3.
+#!/bin/sh
+"""": # -*-python-*-
+bup_python="$(dirname "$0")/../cmd/bup-python" || exit $?
+exec "$bup_python" "$0" ${1+"$@"}
+"""
import os.path, re, subprocess, sys