summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordAniel hAhler <daniel@thequod.de>2008-03-12 01:53:48 +0100
committerJoey Hess <joey@kodama.kitenet.net>2008-04-05 15:07:12 -0400
commite2853acb5205d87d3a01e8e602abaf45489d4207 (patch)
tree8b422f850ee170958394553f2c75675781bc5360
parent82db119e78ded158ded196e96b64f1824ab70567 (diff)
Add commit hook script for bzr to add new files
Committing fails with "bzr", if there are only new files and new files probably never get added. This script adds the files during the "commit" process.
-rwxr-xr-xcommit.d/30bzr-add8
1 files changed, 8 insertions, 0 deletions
diff --git a/commit.d/30bzr-add b/commit.d/30bzr-add
new file mode 100755
index 0000000..62e4bac
--- /dev/null
+++ b/commit.d/30bzr-add
@@ -0,0 +1,8 @@
+#!/bin/sh
+set -e
+
+if [ "$VCS" = bzr ] && [ -d .bzr ]; then
+ if ! bzr add .; then
+ echo "etckeeper warning: bzr add failed" >&2
+ fi
+fi