Merge pull request #142 from jonasc/master

Resolved conflicts, and signed commit from jonasc.
This commit is contained in:
Tim Byrne 2020-01-16 12:59:32 -06:00
commit 3e42bd9f52
No known key found for this signature in database
GPG Key ID: 14DB4FC2465A4B12
1 changed files with 3 additions and 1 deletions

4
yadm
View File

@ -629,6 +629,7 @@ function alt_past_linking() {
# loop over all "tracked" files
# for every file which is a *##yadm.j2 create a real file
local temp="$(mktemp)"
local match="^(.+)##yadm\\.j2$"
for tracked_file in "${tracked_files[@]}" "${ENCRYPT_INCLUDE_FILES[@]}"; do
tracked_file="$YADM_WORK/$tracked_file"
@ -643,7 +644,8 @@ function alt_past_linking() {
YADM_HOSTNAME="$local_host" \
YADM_USER="$local_user" \
YADM_DISTRO="$local_distro" \
"$ENVTPL_PROGRAM" --keep-template "$tracked_file" -o "$real_file"
"$ENVTPL_PROGRAM" --keep-template "$tracked_file" -o "$temp"
mv "$temp" "$real_file"
else
debug "envtpl not available, not creating $real_file from template $tracked_file"
[ -n "$loud" ] && echo "envtpl not available, not creating $real_file from template $tracked_file"