1
0
mirror of https://git.decapod.one/brethil/dotfiles synced 2024-12-29 02:31:32 +01:00

zsh: remove pip completion, fix formatting

This commit is contained in:
bretello 2021-04-08 20:02:37 +02:00
parent f307a2207d
commit 6f5b808787
Signed by: brethil
GPG Key ID: 876AAC6290170FE7

View File

@ -8,7 +8,6 @@ export ZSH_THEME="brethil"
export DISABLE_UNTRACKED_FILES_DIRTY=true
export VIRTUAL_ENV_DISABLE_PROMPT=true
_ZSH_CACHE="${HOME}/.cache/zsh"
if [[ ! -d "${_ZSH_CACHE}" ]]; then mkdir -p "${_ZSH_CACHE}"; fi
@ -56,7 +55,7 @@ export LANG=en_US.UTF-8
export LC_ALL=en_US.UTF-8
# less options
export LESS='-xRF-j12' # -j12: displays 12 lines before search results with / and ?
export LESS='-xRF-j12' # -j12: displays 12 lines before search results with / and ?
if [[ "$(command -v bat)" ]]; then
alias cat=bat
export BAT_THEME="gruvbox-dark"
@ -68,16 +67,6 @@ if [[ $SSH_CLIENT ]]; then
export SSH_AUTH_SOCK=$HOME/.ssh/ssh_auth_sock
fi
# pip completion. Cache output since pip takes 0.4s to run
if [[ ${commands[pip]} ]]; then
pip_cache_file="${_ZSH_CACHE}/pip_completion_cache.zsh"
if [[ "${commands[pip]}" -nt "${pip_cache_file}" || ! -s "$pip_cache_file" ]]; then
pip completion --zsh | sed -e "s|compctl -K [-_[:alnum:]]* pip|& pip2 pip3|" >! "$pip_cache_file" 2> /dev/null
fi
source "${pip_cache_file}"
unset pip_cache_file
fi
alias esource='$EDITOR $HOME/.zshrc'
alias resource='source $HOME/.zshrc'
alias dotedit='$EDITOR $DOTFILES/brethil_dotfile.sh'
@ -88,14 +77,14 @@ alias aledit='$EDITOR ~/.dotfiles_aliases.sh'
export p="${HOME}/projects"
# Extras
functions_file=$DOTFILES/functions.sh # Function definitions
aliases_file=$DOTFILES/aliases.sh # Aliases definitions
colors_file=$DOTFILES/colors.sh # Colors definitions
functions_file=$DOTFILES/functions.sh # Function definitions
aliases_file=$DOTFILES/aliases.sh # Aliases definitions
colors_file=$DOTFILES/colors.sh # Colors definitions
# Source extras
if [ -f "$functions_file" ]; then source "$functions_file"; else echo "[brethil-dotfiles] Couldn't load functions: $functions_file"; fi
if [ -f "$aliases_file" ]; then source "$aliases_file"; else echo "[brethil-dotfiles] Couldn't load aliases: $aliases_file"; fi
if [ -f "$colors_file" ]; then source "$colors_file"; else echo "[brethil-dotfiles] Couldn't load colors: $colors_file";fi
if [ -f "$colors_file" ]; then source "$colors_file"; else echo "[brethil-dotfiles] Couldn't load colors: $colors_file"; fi
### SETUP PATHS ####
export PATH=$PATH:$HOME/bin