mirror of
https://github.com/ryantm/agenix.git
synced 2024-12-26 09:21:56 +03:00
remove newlines in recipient keys file
if not removed, empty lines will be added to the final encryption command as --recipient '' which causes the command to fail with invalid recipient ''
This commit is contained in:
parent
0d5e59ed64
commit
0e2fb13ecf
1 changed files with 1 additions and 1 deletions
|
@ -114,7 +114,7 @@ trap "cleanup" 0 2 3 15
|
|||
|
||||
function edit {
|
||||
FILE=$1
|
||||
KEYS=$((${nixInstantiate} --eval -E "(let rules = import $RULES; in builtins.concatStringsSep \"\n\" rules.\"$FILE\".publicKeys)" | ${sedBin} 's/"//g' | ${sedBin} 's/\\n/\n/g') || exit 1)
|
||||
KEYS=$((${nixInstantiate} --eval -E "(let rules = import $RULES; in builtins.concatStringsSep \"\n\" rules.\"$FILE\".publicKeys)" | ${sedBin} 's/"//g' | ${sedBin} 's/\\n/\n/g') | ${sedBin} '/^$/d' || exit 1)
|
||||
|
||||
if [ -z "$KEYS" ]
|
||||
then
|
||||
|
|
Loading…
Reference in a new issue