resolved #444 add messaging to __line-type (#580)

#444 Add messaging to __line-type
remotes/origin/os_explorer_devuan_fix
Thomas Eckert 8 years ago committed by Darko Poljak
parent e5881301ad
commit 7ee56d099f
  1. 6
      cdist/conf/type/__line/gencode-remote
  2. 7
      cdist/conf/type/__line/man.rst

@ -60,6 +60,7 @@ case "$state_should" in
# Only replace ' with '"'"' and keep \ as they are
line_sanitised=$(cat "$__object/parameter/line" | sed -e "s/'/'\"'\"'/g")
printf '%s' "printf '%s\n' '$line_sanitised' >> $file"
echo "added" >> "$__messages_out"
;;
absent)
@ -83,9 +84,10 @@ fi
grep -v $greparg '$regex' '$file' > \$tmpfile || true
mv -f "\$tmpfile" "$file"
eof
echo "removed" >> "$__messages_out"
;;
*)
echo "Unknown state: $state_should" >&2
exit 1
echo "Unknown state: $state_should" >&2
exit 1
;;
esac

@ -40,6 +40,13 @@ file
If supplied, use this as the destination file.
Otherwise the object_id is used.
MESSAGES
--------
added
The line was added.
removed
The line was removed.
EXAMPLES
--------

Loading…
Cancel
Save