mirror of
https://github.com/dcarrillo/dotfiles.git
synced 2026-07-22 17:54:44 +00:00
Load brew installed commands autocompletion
This commit is contained in:
@@ -7,6 +7,12 @@ if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]
|
|||||||
source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh"
|
source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Add homebrew-installed package completions to fpath
|
||||||
|
if command -v brew > /dev/null; then
|
||||||
|
export BREW_PREFIX=$(brew --prefix)
|
||||||
|
fpath+=$(brew --prefix)/share/zsh/site-functions
|
||||||
|
fi
|
||||||
|
|
||||||
# Source Prezto.
|
# Source Prezto.
|
||||||
if [[ -s "${ZDOTDIR:-$HOME}/.zprezto/init.zsh" ]]; then
|
if [[ -s "${ZDOTDIR:-$HOME}/.zprezto/init.zsh" ]]; then
|
||||||
source "${ZDOTDIR:-$HOME}/.zprezto/init.zsh"
|
source "${ZDOTDIR:-$HOME}/.zprezto/init.zsh"
|
||||||
@@ -52,7 +58,7 @@ alias k=kubectl
|
|||||||
alias kgy='kubectl get -o yaml'
|
alias kgy='kubectl get -o yaml'
|
||||||
alias kready='kubectl get --raw="/readyz?verbose"'
|
alias kready='kubectl get --raw="/readyz?verbose"'
|
||||||
case $(uname) in
|
case $(uname) in
|
||||||
Darwin) alias ls='$(brew --prefix)/bin/gls --group-directories-first --color=auto --hyperlink=auto' ;;
|
Darwin) alias ls='$BREW_PREFIX/bin/gls --group-directories-first --color=auto --hyperlink=auto' ;;
|
||||||
Linux) alias ls='ls --group-directories-first --color=auto --hyperlink=auto' ;;
|
Linux) alias ls='ls --group-directories-first --color=auto --hyperlink=auto' ;;
|
||||||
esac
|
esac
|
||||||
alias neovim=nvim
|
alias neovim=nvim
|
||||||
@@ -133,8 +139,8 @@ export PAGER='less'
|
|||||||
##### fzf #####
|
##### fzf #####
|
||||||
|
|
||||||
case $(uname) in
|
case $(uname) in
|
||||||
Darwin) source "$(brew --prefix)/opt/fzf/shell/key-bindings.zsh"
|
Darwin) source "$BREW_PREFIX/opt/fzf/shell/key-bindings.zsh"
|
||||||
source "$(brew --prefix)/opt/fzf/shell/completion.zsh" ;;
|
source "$BREW_PREFIX/opt/fzf/shell/completion.zsh" ;;
|
||||||
Linux) source /usr/share/fzf/key-bindings.zsh
|
Linux) source /usr/share/fzf/key-bindings.zsh
|
||||||
source /usr/share/fzf/completion.zsh ;;
|
source /usr/share/fzf/completion.zsh ;;
|
||||||
esac
|
esac
|
||||||
@@ -166,8 +172,6 @@ eval "$(atuin init zsh)"
|
|||||||
# aws cli zsh autocomplete
|
# aws cli zsh autocomplete
|
||||||
case $(uname) in
|
case $(uname) in
|
||||||
Linux) source /usr/bin/aws_zsh_completer.sh ;;
|
Linux) source /usr/bin/aws_zsh_completer.sh ;;
|
||||||
Darwin) autoload bashcompinit && bashcompinit
|
|
||||||
complete -C "$(brew --prefix)/bin/aws_completer" aws ;;
|
|
||||||
esac
|
esac
|
||||||
|
|
||||||
# custom device
|
# custom device
|
||||||
|
|||||||
Reference in New Issue
Block a user