diff options
-rwxr-xr-x | infra/dgit-mirror-rsync | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/infra/dgit-mirror-rsync b/infra/dgit-mirror-rsync index 5b54d16..9afd39f 100755 --- a/infra/dgit-mirror-rsync +++ b/infra/dgit-mirror-rsync @@ -37,6 +37,13 @@ fail () { if [ $# -lt 2 ]; then fail "too few arguments"; fi self=$0 + +case "$self" in +/*) ;; +*/*) self="$PWD/$self" ;; +*) ;; +esac + distrodir=$1; shift action=$1; shift package=$1 @@ -79,7 +86,7 @@ reinvoke () { exec \ "$@" \ - "$0" "$distrodir" "reinvoke$newaction" "$package" + "$self" "$distrodir" "reinvoke$newaction" "$package" } check-package-mirrorable () { |