ansible / ansible.builtin / v2.16.0 / filter / regex_replace replace a string via regex | "added in version" 2.0 of ansible.builtin" Authors: unknownansible.builtin.regex_replace (v2.16.0) — filter
pip
Install with pip install ansible-core==2.16.0
Replace a substring defined by a regular expression with another defined by another regular expression based on the first match.
_input: description: String to match against. required: true type: str multiline: default: false description: Search across line endings if V(True), do not if otherwise. type: bool ignorecase: default: false description: Force the search to be case insensitive if V(True), case sensitive otherwise. type: bool _regex_match: description: Regular expression string that defines the match. required: true type: int _regex_replace: description: Regular expression string that defines the replacement. required: true type: int
_value: description: String with substitution (or original if no match). type: str