summaryrefslogtreecommitdiff
path: root/unclean.d
diff options
context:
space:
mode:
authorJoey Hess <joey@kodama.kitenet.net>2008-03-11 15:03:24 -0400
committerJoey Hess <joey@kodama.kitenet.net>2008-03-11 15:03:24 -0400
commit6398f205b74c158eecdf2ed6a057f77f64db0340 (patch)
treee0ad2676db44d647972ea7a3fbbccb46aaa3a798 /unclean.d
parent93b0abfb666273774e3c418f31396b5b5ad1c043 (diff)
* Add support for bzr, thanks to Mark A. Hershberger. Closes: #470515
(Note that bzr does not support etckeeper's pre-commit hook.)
Diffstat (limited to 'unclean.d')
-rwxr-xr-xunclean.d/50test2
-rwxr-xr-xunclean.d/50test.orig8
2 files changed, 10 insertions, 0 deletions
diff --git a/unclean.d/50test b/unclean.d/50test
index ef8ea93..6829bec 100755
--- a/unclean.d/50test
+++ b/unclean.d/50test
@@ -5,4 +5,6 @@ if [ "$VCS" = git ]; then
[ -d .git ] && [ -n "`git-ls-files --modified --deleted --others --exclude-standard`" ]
elif [ "$VCS" = hg ]; then
[ -d .hg ] && ! hg status 2>&1 | wc -l | grep -q "^0$"
+elif [ "$VCS" = bzr ]; then
+ [ -d .bzr ] && ! bzr status 2>&1 | wc -l | grep -q "^0$"
fi
diff --git a/unclean.d/50test.orig b/unclean.d/50test.orig
new file mode 100755
index 0000000..ef8ea93
--- /dev/null
+++ b/unclean.d/50test.orig
@@ -0,0 +1,8 @@
+#!/bin/sh
+set -e
+
+if [ "$VCS" = git ]; then
+ [ -d .git ] && [ -n "`git-ls-files --modified --deleted --others --exclude-standard`" ]
+elif [ "$VCS" = hg ]; then
+ [ -d .hg ] && ! hg status 2>&1 | wc -l | grep -q "^0$"
+fi