Skip to content

Tilde used in zsh completion leads to misconfiguration #21060

@dnechay

Description

@dnechay

Is this a docs issue?

  • My issue is about the documentation content or website

Type of issue

Information is incorrect

Description

Hey 👋🏼
Thank you for amazing tool and docs for it!

I was trying to install autocompletions on MacOS with default zsh setup (no "Oh My Zsh"), followed the step written in the docs page and wasn't able to get it working.
It appeared that when tilde (~) is part of FPATH by some reason autocomplete scrip wasn't loaded/found.

Location

https://docs.docker.com/engine/cli/completion/

Suggestion

Change this snippet

cat <<EOT >> ~/.zshrc
fpath=(~/.docker/completions \\$fpath)
autoload -Uz compinit
compinit
EOT

to use $HOME variable instead of tilde, so

cat <<EOT >> ~/.zshrc
FPATH="\$HOME/.docker/completions:\${FPATH}"
autoload -Uz compinit && compinit
EOT

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions