Commit Graph

25 Commits

Author SHA1 Message Date
David Karlsson b35361e8d2 docs: regenerate stubs for non-canonical commands
Signed-off-by: David Karlsson <35727626+dvdksn@users.noreply.github.com>
2024-01-15 13:49:53 +01:00
David Karlsson a6774de682 docs: rename cli reference aliases to canonical
Signed-off-by: David Karlsson <35727626+dvdksn@users.noreply.github.com>
2024-01-15 11:29:30 +01:00
David Karlsson 6fd4cff1f7 docs: minor editorial improvements, typo fixes
Signed-off-by: David Karlsson <35727626+dvdksn@users.noreply.github.com>
2023-12-19 17:15:38 +01:00
Kevin Alvarez 79c9e527a3
docs: generate markdown
Keep frontmatter for docker, dockerd and index markdown files.
Also needs to move cli.md > docker.md before generation and
then move it back because cli.md is needed for yaml generation on docs
website: https://github.com/docker/cli/pull/3924#discussion_r1059986605

Signed-off-by: Kevin Alvarez <crazy-max@users.noreply.github.com>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-01-06 22:36:47 +01:00
Sebastiaan van Stijn 71e561780a
docs: fix anchor links
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-01-06 17:29:40 +01:00
Sebastiaan van Stijn 80b1285fec cli: use custom annotation for aliases
Cobra allows for aliases to be defined for a command, but only allows these
to be defined at the same level (for example, `docker image ls` as alias for
`docker image list`). Our CLI has some commands that are available both as a
top-level shorthand as well as `docker <object> <verb>` subcommands. For example,
`docker ps` is a shorthand for `docker container ps` / `docker container ls`.

This patch introduces a custom "aliases" annotation that can be used to print
all available aliases for a command. While this requires these aliases to be
defined manually, in practice the list of aliases rarely changes, so maintenance
should be minimal.

As a convention, we could consider the first command in this list to be the
canonical command, so that we can use this information to add redirects in
our documentation in future.

Before this patch:

    docker images --help

    Usage:  docker images [OPTIONS] [REPOSITORY[:TAG]]

    List images

    Options:
      -a, --all             Show all images (default hides intermediate images)
      ...

With this patch:

    docker images --help

    Usage:  docker images [OPTIONS] [REPOSITORY[:TAG]]

    List images

    Aliases:
      docker image ls, docker image list, docker images

    Options:
      -a, --all             Show all images (default hides intermediate images)
      ...

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2022-06-28 17:32:09 +02:00
Sebastiaan van Stijn 47ba76afb1
docs: use "console" code-hint for shell examples
This replaces the use of bash where suitable, to allow easier copy/pasting
of shell examples without copying the prompt or process output.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2021-08-21 18:29:13 +02:00
Sebastiaan van Stijn 6a02a51c99
docs: remove some references to obsolete docker versions
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2020-10-26 18:30:01 +01:00
Sebastiaan van Stijn f30bde6adb
remove unneeded comment from reference files
these markdown files are not consumed directly in the docs,
but only their content is included through the YAML does,
so there's no need to have these comments in them

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2020-03-19 15:15:23 +01:00
wanglei b6def77c55 Developer Certificate of Origin
Version 1.1

Copyright (C) 2004, 2006 The Linux Foundation and its contributors.
1 Letterman Drive
Suite D4700
San Francisco, CA, 94129

Everyone is permitted to copy and distribute verbatim copies of this
license document, but changing it is not allowed.

Developer's Certificate of Origin 1.1

By making a contribution to this project, I certify that:

(a) The contribution was created in whole or in part by me and I
    have the right to submit it under the open source license
    indicated in the file; or

(b) The contribution is based upon previous work that, to the best
    of my knowledge, is covered under an appropriate open source
    license and I have the right under that license to submit that
    work with modifications, whether created in whole or in part
    by me, under the same open source license (unless I am
    permitted to submit under a different license), as indicated
    in the file; or

(c) The contribution was provided directly to me by some other
    person who certified (a), (b) or (c) and I have not modified
    it.

(d) I understand and agree that this project and the contribution
    are public and that a record of the contribution (including all
    personal information I submit with it, including my sign-off) is
    maintained indefinitely and may be redistributed consistent with
    this project or the open source license(s) involved.

Signed-off-by: nkwangleiGIT <nkwanglei@126.com>
2018-05-16 20:16:08 +08:00
Frieder Bluemle 45c9b9b6c1
Fix GitHub spelling
Signed-off-by: Frieder Bluemle <frieder.bluemle@gmail.com>
2017-10-05 01:14:31 +08:00
Kir Kolyshkin 6d85a4f5f8 Fix repo references in docs
Since CLI was moved to a separate repo, these references are incorrect.
Fixed with the help of sed script, verified manually.

Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
2017-07-28 10:32:42 -07:00
Misty Stanley-Jones ddadd3db49 Standardized formatting of CLI reference commands
Command name should be a H1

Only Description, Examples, and Related Commands should be H2

Changed 'Related information' heading to 'Related commands' since 99% it is only linking commands

Added some examples where relevant

Signed-off-by: Misty Stanley-Jones <misty@docker.com>
2017-06-02 00:10:53 +00:00
Gaetan de Villele 572c6bb89a fix frontmatter keywords value type (string, instead of []string) in /docs/reference
Signed-off-by: Gaetan de Villele <gdevillele@gmail.com>
2017-06-02 00:10:31 +00:00
yuexiao-wang f18c41ee83 Modify the links for docker container commands
Signed-off-by: yuexiao-wang <wang.yuexiao@zte.com.cn>
2017-06-02 00:10:27 +00:00
Misty Stanley-Jones 7f36c3a1a0 Sync docker/docker refs with files mistakenly edited in docker.github.io repo
Signed-off-by: Misty Stanley-Jones <misty@docker.com>
2017-06-02 00:10:26 +00:00
Misty Stanley-Jones 2845676cc2 Convert Markdown frontmatter to YAML
Some frontmatter such as the weights, menu stuff, etc is no longer used
'draft=true' becomes 'published: false'

Signed-off-by: Misty Stanley-Jones <misty@docker.com>
2017-06-02 00:10:24 +00:00
Vincent Demeester 3ebe3fe752 Updates on cli reference documentation
- Update ps with `--last` flag
- Update commands with current output
- Make sure hugo does not detect the wrong language
- Update usage for `tag` command to be more coherent with the other ones

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
2017-06-02 00:07:49 +00:00
Victoria Bialas d3b7a2779e surfacing Learn by example topics to top level of Docker Engine docs
fixing links after moving surfacing tutorials

fixing more links for the newly located tutorials

Signed-off-by: Victoria Bialas <victoria.bialas@docker.com>
2017-06-02 00:07:43 +00:00
Mary Anthony 7910f01804 Creating Engine specific menu
Fixing the links
Updating with Seb's comments
Adding weight
Fixing the engine aliases
Updating after Arun pushed
Removing empty file

Signed-off-by: Mary Anthony <mary@docker.com>
2017-06-02 00:07:26 +00:00
Doug Davis 421578fbd4 remove =false from options that default to false in the docs
This re-aligns the docs with what the cmd line now does.

Signed-off-by: Doug Davis <dug@us.ibm.com>
2017-06-02 00:07:21 +00:00
Mary Anthony e641a0f363 Enabled GitHub Flavored Markdown
GitHub flavored markdown is now supported for links and images. Also, ran LinkChecker and FileResolver. Yay!
Fixes from Spider check
Output for docker/docker now goes into engine directory

Signed-off-by: Mary Anthony <mary@docker.com>
2017-06-02 00:07:12 +00:00
Mary Anthony d45666f869 Fixing issues in command ordering. Adding index.md
Adjust bullets
Entering Seb's comments

Signed-off-by: Mary Anthony <mary@docker.com>
2017-06-02 00:07:11 +00:00
Antonio Murdaca cbd33a2b27 Fix man and commandline docs
- missing help option in `docs/reference/commandline/*.md` (some files
  have it, the other I fixed didn't)
- missing `[OPTIONS]` in Usage description
- missing options
- formatting
- start/stop idempotence

Signed-off-by: Antonio Murdaca <amurdaca@redhat.com>
2017-06-02 00:07:11 +00:00
Mary Anthony 4f9fac3803 Splitting out the cli command into parts.
Signed-off-by: Mary Anthony <mary@docker.com>
2017-06-02 00:06:59 +00:00