Remove erroneous extra-vars example, and a few really old versionadded indicators. Fixes #38415 (#49955)

This commit is contained in:
Matt Martz 2018-12-14 17:09:25 -06:00 committed by Alicia Cozine
parent 16f48bb4be
commit 67ce743cc9
1 changed files with 0 additions and 24 deletions

View File

@ -962,31 +962,11 @@ key=value format::
.. note:: Values passed in using the ``key=value`` syntax are interpreted as strings.
Use the JSON format if you need to pass in anything that shouldn't be a string (Booleans, integers, floats, lists etc).
.. versionadded:: 1.2
JSON string format::
ansible-playbook release.yml --extra-vars '{"version":"1.23.45","other_variable":"foo"}'
ansible-playbook arcade.yml --extra-vars '{"pacman":"mrs","ghosts":["inky","pinky","clyde","sue"]}'
.. versionadded:: 1.3
YAML string format::
ansible-playbook release.yml --extra-vars '
version: "1.23.45"
other_variable: foo'
ansible-playbook arcade.yml --extra-vars '
pacman: mrs
ghosts:
- inky
- pinky
- clyde
- sue'
.. versionadded:: 1.3
vars from a JSON or YAML file::
ansible-playbook release.yml --extra-vars "@some_file.json"
@ -995,8 +975,6 @@ This is useful for, among other things, setting the hosts group or the user for
Escaping quotes and other special characters:
.. versionadded:: 1.2
Ensure you're escaping quotes appropriately for both your markup (e.g. JSON), and for
the shell you're operating in.::
@ -1004,8 +982,6 @@ the shell you're operating in.::
ansible-playbook arcade.yml --extra-vars '{"name":"Conan O'\\\''Brien"}'
ansible-playbook script.yml --extra-vars "{\"dialog\":\"He said \\\"I just can\'t get enough of those single and double-quotes"\!"\\\"\"}"
.. versionadded:: 1.3
In these cases, it's probably best to use a JSON or YAML file containing the variable
definitions.