WIP: reference: show aliases for commands#17511
WIP: reference: show aliases for commands#17511thaJeztah wants to merge 1 commit intodocker:mainfrom
Conversation
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
✅ Deploy Preview for docsdocker ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
| The following commands are equivalent and redirect here: | ||
| {% for alias in aliases %} | ||
| {%- assign fname = alias | remove_first: "docker " | replace: " ", "_" -%} | ||
| - [{{ alias }}](/engine/reference/commandline/{{ fname }}/) |
There was a problem hiding this comment.
I constructed the URLs for each alias here, but this won't work because we don't have redirects for all aliases.
Some options;
- (for now) just show the aliases only (without a link)
- add redirects for all aliases
- ^^^ but if we do, we need to update those redirects to the canonical URL once we moved the content (see Reference docs: use canonical URL / command names #10471 and [WIP] reorganise reference docs cli#2389)
- ^^^ if we add redirects now, those would already have a "moved permanently" redirect, so I'm not sure if it's a good idea to do that if we'll be updating the location in future (SEO-wise)
There was a problem hiding this comment.
Also, this list does not filter out the "current" page from the list; perhaps that's what we want, or perhaps we want to exclude the "current alias" here (not sure what's best)
I should add here tha
- (if I did it right everywhere), the first "alias" in the list is considered the "canonical", and ultimately should be the page we redirect them all to, but content would still have to be moved (and we need to review if all those are indeed what we consider the "canonical")
- "build" is still a tricky one;
docker image buildis probably the canonical one, butdocker buildx buildcan in some cases provide additional options / ever-so-slightly different behavior, so may not be an "exact" alias. - ^^ documentation is also still spread between
docker buildanddocker buildx build
|
Thanks for the pull request. We'd like to make our product docs better, but haven’t been able to review all the suggestions. If the updates are still relevant, review our contribution guidelines and rebase your pull request against the latest version of the docs, then mark it as fresh with a Prevent pull requests from auto-closing with a /lifecycle stale |
|
Thanks for the pull request. We'd like to make our product docs better, but haven’t been able to review all the suggestions. If the updates are still relevant, review our contribution guidelines and rebase your pull request against the latest version of the docs, then mark it as fresh with a Prevent pull requests from auto-closing with a /lifecycle stale |
Proposed changes
Related issues (optional)