Add note to formatting section (#11326)

* Add note to formatting section

* Add note to formatting section

* Fix the double quote to single quote

* Fix description

* Minor style updates

Co-authored-by: Maximillian Fan Xavier <maximillianfx@ibm.com>
Co-authored-by: Usha Mandya <47779042+usha-mandya@users.noreply.github.com>
This commit is contained in:
Maximillian Xavier 2020-09-04 08:35:18 -03:00 committed by GitHub
parent fa0663ea89
commit 0c55a6ddcf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 22 additions and 0 deletions

View File

@ -14,6 +14,28 @@ All of these examples use the `docker inspect` command, but many other CLI
commands have a `--format` flag, and many of the CLI command references
include examples of customizing the output format.
>**Note**
>
> Whe using the `--format` flag, you need observe your shell environment.
> In a Posix shell, you can run the following with a single quote:
>
> {% raw %}
> ```bash
> docker inspect --format '{{join .Args " , "}}'
> ```
> {% endraw %}
>
> Otherwise, in a Windows shell (for example, PowerShell), you need to use single quotes, but
> escape the double quotes inside the params as follows:
>
> {% raw %}
> ```bash
> docker inspect --format '{{join .Args \" , \"}}'
> ```
> {% endraw %}
>
{:.important}
## join
`join` concatenates a list of strings to create a single string.