From 1f22dbd2fbe287442e4216b3eee0a339e36235bb Mon Sep 17 00:00:00 2001 From: Brian Zalewski Date: Tue, 24 Jan 2023 23:43:15 +0000 Subject: [PATCH] Update file run_before_01-decrypt-age-key.tmpl --- .../universal/run_before_01-decrypt-age-key.tmpl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/home/.chezmoiscripts/universal/run_before_01-decrypt-age-key.tmpl b/home/.chezmoiscripts/universal/run_before_01-decrypt-age-key.tmpl index 3b391a97..52e5b74f 100644 --- a/home/.chezmoiscripts/universal/run_before_01-decrypt-age-key.tmpl +++ b/home/.chezmoiscripts/universal/run_before_01-decrypt-age-key.tmpl @@ -18,8 +18,8 @@ if [ ! -f "${XDG_CONFIG_HOME}/age/chezmoi.txt" ]; then rm -f "$ENCRYPTED_FILE" FALLBACK_FILENAME="$(echo "$ENCRYPTED_FILE" | sed 's/encrypted_/encrypted-fallback_/')" if [ -f "$FALLBACK_FILENAME" ]; then - NEW_FALLBACK_FILENAME="$(echo "$ENCRYPTED_FILE" | sed 's/encrypted-fallback_//')" - cp "$FALLBACK_FILENAME" "$NEW_FALLBACK_FILENAME" + logg info 'Substituting encrypted-file fallback for `'"$ENCRYPTED_FILE"'`' + cp -f "$FALLBACK_FILENAME" "$(echo "$ENCRYPTED_FILE" | sed 's/encrypted_//')" fi done fi