Skip to content

Commit 826e2a4

Browse files
committed
Fix indentation issues introduced in #2095.
1 parent 8e25d90 commit 826e2a4

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

docs/docsite/rst/playbook_guide/playbooks_error_handling.rst

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -179,16 +179,16 @@ You can reference simple variables in conditionals to avoid repeating certain te
179179
- name: Example playbook
180180
hosts: myHosts
181181
vars:
182-
log_path: /home/ansible/logfolder/
183-
log_file: log.log
182+
log_path: /home/ansible/logfolder/
183+
log_file: log.log
184184
185-
tasks:
185+
tasks:
186186
- name: Create empty log file
187-
ansible.builtin.shell: mkdir {{ log_path }} || touch {{log_path }}{{ log_file }}
188-
register: tmp
189-
changed_when:
190-
- tmp.rc == 0
191-
- 'tmp.stderr != "mkdir: cannot create directory ‘" ~ log_path ~ "’: File exists"'
187+
ansible.builtin.shell: mkdir {{ log_path }} || touch {{log_path }}{{ log_file }}
188+
register: tmp
189+
changed_when:
190+
- tmp.rc == 0
191+
- 'tmp.stderr != "mkdir: cannot create directory ‘" ~ log_path ~ "’: File exists"'
192192
193193
.. note::
194194
Notice the missing double curly braces ``{{ }}`` around the ``log_path`` variable in the ``changed_when`` statement.

0 commit comments

Comments
 (0)