mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-08-02 04:04:23 -07:00
Fix order of version_compare arguments in porting guide (#15809)
I struggled with this for quite a while trying to figure out the right quoting before I discovered that the arguments to `version_compare` were reversed.
This commit is contained in:
parent
71c97685a1
commit
243af8f727
1 changed files with 1 additions and 1 deletions
|
@ -26,7 +26,7 @@ To make an escaped string that will work on all versions you have two options::
|
||||||
|
|
||||||
uses key=value escaping which has not changed. The other option is to check for the ansible version::
|
uses key=value escaping which has not changed. The other option is to check for the ansible version::
|
||||||
|
|
||||||
"{{ (ansible_version|version_compare('ge', '2.0'))|ternary( 'test1_junk 1\\3' | regex_replace('(.*)_junk (.*)', '\\1 \\2') , 'test1_junk 1\\\\3' | regex_replace('(.*)_junk (.*)', '\\\\1 \\\\2') ) }}"
|
"{{ (ansible_version|version_compare('2.0', 'ge'))|ternary( 'test1_junk 1\\3' | regex_replace('(.*)_junk (.*)', '\\1 \\2') , 'test1_junk 1\\\\3' | regex_replace('(.*)_junk (.*)', '\\\\1 \\\\2') ) }}"
|
||||||
|
|
||||||
* trailing newline When a string with a trailing newline was specified in the
|
* trailing newline When a string with a trailing newline was specified in the
|
||||||
playbook via yaml dict format, the trailing newline was stripped. When
|
playbook via yaml dict format, the trailing newline was stripped. When
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue