Closed nicutor closed 6 years ago
The correct way is this:
augeas 'include_some_file' do
changes ['ins 01 before /files/root/tmp/1', 'set /files/root/tmp/01 Include /some/file']
lens 'Simplelines.lns'
incl '/root/tmp'
run_if "match /files/root/tmp/*[. = 'Include /some/file'] size == 0"
end
Thanks to @lutter
Hi,
I have this file /root/tmp
I am trying to add a new line on it, only if that line doesn't exist using:
and I get this error:
I've also tried:
The command
runs well, I just don't know how to compare it to get a return code for run_if
Can you please guide me on the right direction?
Thank you.