diff --git a/docs/docsite/rst/plugins/lookup.rst b/docs/docsite/rst/plugins/lookup.rst index 31183b15c49..21845d9357c 100644 --- a/docs/docsite/rst/plugins/lookup.rst +++ b/docs/docsite/rst/plugins/lookup.rst @@ -36,13 +36,13 @@ You can use lookup plugins anywhere you can use templating in Ansible: in a play .. code-block:: YAML+Jinja vars: - file_contents: "{{lookup('file', 'path/to/file.txt')}}" + file_contents: "{{ lookup('file', 'path/to/file.txt') }}" Lookups are an integral part of loops. Wherever you see ``with_``, the part after the underscore is the name of a lookup. For this reason, most lookups output lists and take lists as input; for example, ``with_items`` uses the :ref:`items ` lookup:: tasks: - name: count to 3 - debug: msg={{item}} + debug: msg={{ item }} with_items: [1, 2, 3] You can combine lookups with :ref:`filters `, :ref:`tests ` and even each other to do some complex data generation and manipulation. For example:: @@ -51,8 +51,8 @@ You can combine lookups with :ref:`filters `, :ref:`tests