summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJason A. Donenfeld <Jason@zx2c4.com>2016-02-06 20:41:54 +0100
committerJason A. Donenfeld <Jason@zx2c4.com>2016-02-06 20:41:54 +0100
commit76382f160d90b3a6c6599d759138a4d3b2409d4f (patch)
treeac5ad3d45719e9b3849a3e5434d0a71abb0dd627 /src
parent5e85ea875bc234b70a7ff5294fdea11b9c8f3d63 (diff)
downloadpass-76382f160d90b3a6c6599d759138a4d3b2409d4f.tar.gz
pass-76382f160d90b3a6c6599d759138a4d3b2409d4f.tar.bz2
pass-76382f160d90b3a6c6599d759138a4d3b2409d4f.zip
init: put path in commit message
Diffstat (limited to '')
-rwxr-xr-xsrc/password-store.sh8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/password-store.sh b/src/password-store.sh
index 7e9fcb0..032df7f 100755
--- a/src/password-store.sh
+++ b/src/password-store.sh
@@ -279,19 +279,19 @@ cmd_init() {
rm -v -f "$gpg_id" || exit 1
if [[ -d $GIT_DIR ]]; then
git rm -qr "$gpg_id"
- git_commit "Deinitialize ${gpg_id}."
+ git_commit "Deinitialize ${gpg_id}${id_path:+ ($id_path)}."
fi
rmdir -p "${gpg_id%/*}" 2>/dev/null
else
mkdir -v -p "$PREFIX/$id_path"
printf "%s\n" "$@" > "$gpg_id"
local id_print="$(printf "%s, " "$@")"
- echo "Password store initialized for ${id_print%, }"
- git_add_file "$gpg_id" "Set GPG id to ${id_print%, }."
+ echo "Password store initialized for ${id_print%, }${id_path:+ ($id_path)}"
+ git_add_file "$gpg_id" "Set GPG id to ${id_print%, }${id_path:+ ($id_path)}."
fi
reencrypt_path "$PREFIX/$id_path"
- git_add_file "$PREFIX/$id_path" "Reencrypt password store using new GPG id ${id_print%, }."
+ git_add_file "$PREFIX/$id_path" "Reencrypt password store using new GPG id ${id_print%, }${id_path:+ ($id_path)}."
}
cmd_show() {