Merge pull request #349 from asteven/issue/349

__block creates duplicates
remotes/origin/random_dot_cdist
Nico Schottelius 11 years ago
commit 698be8e5b6
  1. 6
      cdist/conf/type/__block/gencode-remote

@ -46,13 +46,13 @@ tmpfile=\$(mktemp ${file}.cdist.XXXXXXXXXX)
if [ -f "$file" ]; then
cp -p "$file" "\$tmpfile"
fi
awk -v prefix="^$prefix\\\$" -v suffix="^$suffix\\\$" '
awk -v prefix="^$prefix\$" -v suffix="^$suffix\$" '
{
if (index(\$0,prefix)) {
if (match(\$0,prefix)) {
triggered=1
}
if (triggered) {
if (index(\$0,suffix)) {
if (match(\$0,suffix)) {
triggered=0
}
} else {

Loading…
Cancel
Save