Skip to content

Commit

Permalink
fix: docker zsh completion
Browse files Browse the repository at this point in the history
  • Loading branch information
tainvecs committed Feb 22, 2025
1 parent 5b65114 commit 75c8c47
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions config/zsh/.zshrc_completion.zsh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
ZINIT[COMPINIT_OPTS]=-C


# Download completion files
# Prepare completion files

# docker and docker compose
if type docker >"/dev/null"; then
Expand All @@ -14,10 +14,7 @@ if type docker >"/dev/null"; then
local _docker_cmp_path="${DOTFILES[CONFIG_DIR]}/zsh/.zsh_complete/_docker"
local _docker_cmp_link="${DOTFILES[HOME_DIR]}/.zsh/.zsh_complete/_docker"

if [[ ! -f $_docker_cmp_path ]]; then
curl -sfLo $_docker_cmp_path \
"https://raw.githubusercontent.com/docker/cli/master/contrib/completion/zsh/_docker"
fi
[[ -f $_docker_cmp_path ]] || docker completion zsh > $_docker_cmp_path
[[ -L $_docker_cmp_link || -f $_docker_cmp_link ]] || ln -s $_docker_cmp_path $_docker_cmp_link

# docker compose
Expand All @@ -44,7 +41,6 @@ if [[ ${DOTFILES_PLUGINS[forgit]} = "true" ]]; then
[[ -L $_forgit_cmp_link || -f $_forgit_cmp_link ]] || ln -s $_forgit_cmp_path $_forgit_cmp_link
fi


# gcp
if type gcloud >"/dev/null"; then
local _gcp_cmp_script_path="${DOTFILES[HOME_DIR]}/.gcp/google-cloud-sdk/completion.zsh.inc"
Expand Down

0 comments on commit 75c8c47

Please sign in to comment.