From b363ed6f7be97658e8c148e05fabc6bb12f993a4 Mon Sep 17 00:00:00 2001 From: Federico Angelilli Date: Sat, 13 Jan 2024 23:19:56 +0100 Subject: Change action evaluation --- crypt.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/crypt.sh b/crypt.sh index 661abe6..b904d76 100755 --- a/crypt.sh +++ b/crypt.sh @@ -461,7 +461,9 @@ _cmd_action_file() { *) error "Unknown action" ;; esac - eval "$action" "$tmp_file" + # Set environment + set -- "$tmp_file" "$path" "${entries_name[$entry]}" + eval "$action" [[ -f $tmp_file ]] || error "File not saved." $GPG -d -o - "${GPG_OPTS[@]}" "$file" 2>/dev/null | diff - "$tmp_file" &>/dev/null && \ -- cgit v1.2.3