chiark
/
gitweb
/
~ianmdlvl
/
dgit.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f7724dc
)
Mirroring: dgit-mirror-rsync copes with invocation via relative pathname
author
Ian Jackson
<ijackson@chiark.greenend.org.uk>
Sat, 11 Jul 2015 16:36:34 +0000
(17:36 +0100)
committer
Ian Jackson
<ijackson@chiark.greenend.org.uk>
Sat, 11 Jul 2015 18:31:19 +0000
(19:31 +0100)
infra/dgit-mirror-rsync
patch
|
blob
|
history
diff --git
a/infra/dgit-mirror-rsync
b/infra/dgit-mirror-rsync
index 5b54d16cc0f9a1cdbf0be5251d1943b5f5d3d535..9afd39f1659c62de4114dd84dd9f6ae4a3fdcca7 100755
(executable)
--- 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 () {