1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

make lineinfile docs clearer and make module pep8 (#23857)

This commit is contained in:
Sloane Hertel 2017-04-23 03:19:22 -04:00 committed by René Moser
parent 35e03cb140
commit 00ebd0c89d
2 changed files with 4 additions and 4 deletions

View file

@ -55,7 +55,7 @@ options:
description:
- The regular expression to look for in every line of the file. For
C(state=present), the pattern to replace if found; only the last line
found will be replaced. For C(state=absent), the pattern of the line
found will be replaced. For C(state=absent), the pattern of the line(s)
to remove. Uses Python regular expressions; see
U(http://docs.python.org/2/library/re.html).
state:
@ -379,6 +379,7 @@ def absent(module, dest, regexp, line, backup):
found = []
b_line = to_bytes(line, errors='surrogate_or_strict')
def matcher(b_cur_line):
if regexp is not None:
match_found = bre_c.search(b_cur_line)

View file

@ -418,7 +418,6 @@ lib/ansible/modules/files/copy.py
lib/ansible/modules/files/find.py
lib/ansible/modules/files/ini_file.py
lib/ansible/modules/files/iso_extract.py
lib/ansible/modules/files/lineinfile.py
lib/ansible/modules/files/patch.py
lib/ansible/modules/files/replace.py
lib/ansible/modules/files/stat.py