summaryrefslogtreecommitdiffstats
path: root/commitpkg
diff options
context:
space:
mode:
authorPierre Schmitz <pierre@archlinux.de>2010-02-11 15:19:13 +0100
committerPierre Schmitz <pierre@archlinux.de>2010-02-11 15:19:13 +0100
commit72a2b4789aba6188003deeb02d35e384e70656f8 (patch)
tree04aaff2c1b35c8feea203836a0f0a878f31ac875 /commitpkg
parent30cfcdc501caacb4b27c8ecc0d0cef3c8a1a6df8 (diff)
downloaddevtools-72a2b4789aba6188003deeb02d35e384e70656f8.tar.gz
devtools-72a2b4789aba6188003deeb02d35e384e70656f8.tar.xz
abort if not all local source files are under version control
This looks a little hacky. The || true is needed because grep will return 1 if in fact everything is fine. implements FS#18048
Diffstat (limited to 'commitpkg')
-rwxr-xr-xcommitpkg7
1 files changed, 7 insertions, 0 deletions
diff --git a/commitpkg b/commitpkg
index 11e345d..c7a8b51 100755
--- a/commitpkg
+++ b/commitpkg
@@ -49,6 +49,13 @@ else
shift
fi
+# check if all local source files are under version control
+(for s in ${source[@]}; do
+ echo $s | grep -vq '://' && \
+ svn status $s | grep -q '?' && \
+ abort "$s is not under version control"
+done) || true
+
# see if any limit options were passed, we'll send them to SCP
unset rsyncopts
if [ "$1" = "-l" ]; then