Hi,
I got stuck with the following:
Imagine we have a string in stdout of a command that we would like to
filter out:
Error123: some 'thing' (happened)
If we want to filter that out we would do something like
"{{ item.stderr.regex_replace('Error[0-9]+: some \\'thing\\'
\\(happened\\)', '') }}"
However due to the fact that we have a colon, a single quote and brackets
in our string I was unable to come up with the right escape sequence -
whatever I tried, it always failed on one of these.
What would be the right way to escape these special character when they are
also used in
the filter function like regex_replace?
Thanks!
--
You received this message because you are subscribed to the Google Groups
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/ansible-project/22408673-cb65-4f5e-b00e-4e2303254c56%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.