dotfiles/dot_zshrc

204 lines
6.9 KiB
Plaintext

# Enable Powerlevel10k instant prompt. Should stay close to the top of ~/.zshrc.
# Initialization code that may require console input (password prompts, [y/n]
# confirmations, etc.) must go above this block; everything else may go below.
if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]; then
source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh"
fi
# Path to your oh-my-zsh installation.
export ZSH=/home/kellya/.oh-my-zsh
# Set name of the theme to load.
# Look in ~/.oh-my-zsh/themes/
# Optionally, if you set this to "random", it'll load a random theme each
# time that oh-my-zsh is loaded.
#ZSH_THEME="agnoster"
ZSH_THEME="powerlevel10k/powerlevel10k"
# Uncomment the following line to use case-sensitive completion.
# CASE_SENSITIVE="true"
# Uncomment the following line to disable bi-weekly auto-update checks.
# DISABLE_AUTO_UPDATE="true"
# Uncomment the following line to change how often to auto-update (in days).
# export UPDATE_ZSH_DAYS=13
# Uncomment the following line to disable colors in ls.
# DISABLE_LS_COLORS="true"
# Uncomment the following line to disable auto-setting terminal title.
# DISABLE_AUTO_TITLE="true"
# Uncomment the following line to enable command auto-correction.
# ENABLE_CORRECTION="true"
# Uncomment the following line to display red dots whilst waiting for completion.
COMPLETION_WAITING_DOTS="true"
# Uncomment the following line if you want to disable marking untracked files
# under VCS as dirty. This makes repository status check for large repositories
# much, much faster.
# DISABLE_UNTRACKED_FILES_DIRTY="true"
# Uncomment the following line if you want to change the command execution time
# stamp shown in the history command output.
# The optional three formats: "mm/dd/yyyy"|"dd.mm.yyyy"|"yyyy-mm-dd"
# HIST_STAMPS="mm/dd/yyyy"
HIST_STAMPS="yyyy-mm-dd"
# Would you like to use another custom folder than $ZSH/custom?
# ZSH_CUSTOM=/path/to/new-custom-folder
# Which plugins would you like to load? (plugins can be found in ~/.oh-my-zsh/plugins/*)
# Custom plugins may be added to ~/.oh-my-zsh/custom/plugins/
# Example format: plugins=(rails git textmate ruby lighthouse)
# Add wisely, as too many plugins slow down shell startup.
# plugins=(git)
plugins=(sudo taskwarrior timewarrior common-aliases git-flow vi-mode fzf python poetry)
#plugins+=(zsh-vi-mode)
plugins+=(fzf-tab)
plugins+=(docker)
# User configuration
export PATH="/usr/lib64/qt-3.3/bin:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/bin:/sbin:/home/kellya/bin:/home/kellya/incoming/git-annex.linux:/home/kellya/bin/keybase/bin:/home/kellya/.local/bin:/home/kellya/.cargo/bin"
# export MANPATH="/usr/local/man:$MANPATH"
DISABLE_AUTO_UPDATE='true'
source $ZSH/oh-my-zsh.sh
source ~/dotfiles/zsh/zsh-git-prompt/zshrc.sh
RPS1='$(git_super_status)'
#source ~/.autoenv/activate.sh
# changing over to direnv from autoenv
eval "$(direnv hook zsh)"
# Add PS1 for python virtualenv in direnv
show_virtual_env() {
if [[ -n "$VIRTUAL_ENV" && -n "$DIRENV_DIR" ]]; then
echo "($(basename $VIRTUAL_ENV))"
fi
}
PS1='$(show_virtual_env)'$PS1
#--------- End of direnv block ------------------------------------------------
unsetopt histverify
alias rtask="task rc:/home/kellya/.taskrc_tinslin"
alias icat="kitty +kitten icat"
alias d="kitty +kitten diff"
#eval "$(ntfy shell-integration)"
#source /usr/share/gems/gems/tmuxinator-0.6.11/completion/tmuxinator.zsh
source ~/.private_aliases
#Load taskwarrior alias file
source ~/.taskwarrior_aliases/taskwarrior_aliases
source /usr/bin/virtualenvwrapper.sh
#Aliases
alias dum='du -sh *|egrep ".*\.?[0-9]M"'
alias shrug='curl shrug.io|xclip'
alias weather='curl wttr.in'
alias ipython='ipython --no-confirm-exit'
#Variable Exports
export EDITOR='nvim'
export PATH="$PATH:/home/kellya/go/bin"
#export WORKON_HOME=/mnt/vdisks/projects/python_virtualenvs
export LPASS_AGENT_TIMEOUT=0
export PATH="/usr/local/heroku/bin:$PATH"
export OPENCV_LOG_LEVEL=OFF
export PATH="/home/kellya/node_modules/.bin/:$PATH"
#Source all the custom functions
# Load custom functions
for f (~/.functions/**/*(N.)) . $f
#This didn't work, but I'll leave it here in case someday it does
#export AGNOSTER_PROMPT_SEGMENTS=("prompt_status" "prompt_context" "prompt_virtualenv" "prompt_dir" "prompt_end")
#cat /home/kellya/.local/share/franklinlogo.txt
#Stop the annoying git prompt
prompt_git () {
:
}
# hyperdrive autocomplete setup
HYPERDRIVE_AC_ZSH_SETUP_PATH=/home/kellya/.cache/hyperdrive-daemon/autocomplete/zsh_setup && test -f $HYPERDRIVE_AC_ZSH_SETUP_PATH && source $HYPERDRIVE_AC_ZSH_SETUP_PATH;
alias vi=nvim
alias ashow="litecli --auto-vertical-output /home/kellya/snap/accountable2you/common/storage.db -e \"select * from log;\""
alias akill="litecli --auto-vertical-output /home/kellya/snap/accountable2you/common/storage.db -e \"delete from log;\""
alias mutt="neomutt"
fpath+=~/.zfunc
kitty + complete setup zsh | source /dev/stdin
#
# Enable 'z' tracking for directory speediness
# Temporarily disabiling while using fasd
# source /usr/libexec/z.sh
#function chpwd() {
# if [ -r $PWD/.zsh_config ]; then
# source $PWD/.zsh_config
# else
# source $HOME/.zshrc
# fi
#}
#
#FZF stuff
#source /usr/share/fzf/shell/key-bindings.zsh
zvm_after_init_commands+=('[ -f /usr/share/fzf/shell/key-bindings.zsh ] && source /usr/share/fzf/shell/key-bindings.zsh')
#source ~/.oh-my-zsh/completions/fzf_completion
export FZF_DEFAULT_OPTS="--extended"
export FZF_DEFAULT_COMMAND="fd --type f"
export FZF_CTRL_T_COMMAND="$FZF_DEFAULT_COMMAND"
#XDG stuff
export XDG_DATA_HOME=$HOME/.local/share
export XDG_CONFIG_HOME=$HOME/.config
export XDG_STATE_HOME=$HOME/.local/state
#ZVM customizations
# Cursors seem backwards, swap 'em
ZVM_INSERT_MODE_CURSOR=$ZVM_CURSOR_BLOCK
ZVM_NORMAL_MODE_CURSOR=$ZVM_CURSOR_BEAM
ZVM_OPPEND_MODE_CURSOR=$ZVM_CURSOR_UNDERLINE
# defaults to last, make each line always insert
ZVM_LINE_INIT_MODE=$ZVM_MODE_INSERT
chezmoi completion zsh | source /dev/stdin
#Trying out fasd over z. There's nothing wrong with z, it just looks like fasd might add some more completion and stuff that might be useful
#eval "$(fasd --init auto)"
#Attempting to try zplug
source ~/.zplug/init.zsh
#zplug "wookayin/fzf-fasd"
zplug "plugins/git", from:oh-my-zsh
autoload -U compinit
compinit -i
PROG=tea _CLI_ZSH_AUTOCOMPLETE_HACK=1 source /home/kellya/.config/tea/autocomplete.zsh
# To customize prompt, run `p10k configure` or edit ~/.p10k.zsh.
[[ ! -f ~/.p10k.zsh ]] || source ~/.p10k.zsh
export PATH="/home/kellya/.deta/bin:$PATH"
export PATH="/home/kellya/local/share/JetBrains/Toolbox/scripts:$PATH"
#eval $(thefuck --alias)
eval "$(zoxide init zsh)"
eval "$(op completion zsh)"; compdef _op op
source /usr/share/zsh-autosuggestions/zsh-autosuggestions.zsh
. "/home/kellya/.acme.sh/acme.sh.env"
# bun completions
[ -s "/home/kellya/.local/share/reflex/bun/_bun" ] && source "/home/kellya/.local/share/reflex/bun/_bun"
# bun
export BUN_INSTALL="$HOME/.local/share/reflex/bun"
export PATH="$BUN_INSTALL/bin:$PATH"