summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2019-03-25 18:25:11 -0300
committerSilvio Rhatto <rhatto@riseup.net>2019-03-25 18:25:11 -0300
commitc46d0e777993c3362b5512f091a84e79b7048fc2 (patch)
tree0adafa536896c4df17092ad68398a3f7e0310c13 /lib
parentbfb19958de60135f98deec6089cd291b43ba9d9c (diff)
downloadkeyringer-c46d0e777993c3362b5512f091a84e79b7048fc2.tar.gz
keyringer-c46d0e777993c3362b5512f091a84e79b7048fc2.tar.bz2
Adds COMMIT_AFTER_ENCRYPT setting
Diffstat (limited to 'lib')
-rwxr-xr-xlib/keyringer/actions/encrypt5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/keyringer/actions/encrypt b/lib/keyringer/actions/encrypt
index 11db62c..e25ad6c 100755
--- a/lib/keyringer/actions/encrypt
+++ b/lib/keyringer/actions/encrypt
@@ -124,5 +124,10 @@ if [ -d "$BASEDIR/.git" ]; then
keyringer_exec git "$BASEDIR" add "keys/$FILE"
fi
+# Optional commit depending on the value of this setting
+if [ "$COMMIT_AFTER_ENCRYPT" == "yes" ]; then
+ keyringer_exec git "$BASEDIR" commit -m "Changes for $FILE"
+fi
+
# Done
exit "$?"