dots/.zshrc

60 lines
1.2 KiB
Bash

if [[ ! $(tmux ls) ]] 2> /dev/null; then
tmux new -s λ
fi
############
### P10K ###
############
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
[[ ! -f ~/.p10k.zsh ]] || source ~/.p10k.zsh
#############
### ZINIT ###
#############
source ~/.zinit.zsh
source ~/.zstyle.zsh
#############
### PATHS ###
#############
# n
export N_PREFIX=$HOME/.n
export PATH=$N_PREFIX/bin:$PATH
#####################
### ENV VARIABLES ###
#####################
export SUDO_EDITOR="nvim"
export EDITOR="nvim"
export VISUAL="nvim"
HISTSIZE=10000
SAVEHIST=50000
HISTFILE=${XDG_STATE_HOME:-$HOME/.local/state}/.zsh_history
###############
### ALIASES ###
###############
alias svim="sudo -E -s nvim"
alias dots='/usr/bin/git --git-dir=$HOME/.git/ --work-tree=$HOME'
alias vim="nvim"
alias vi="nvim"
alias python="python3"
# If wsl.conf exists we're probably in WSL and need some changes for terminal commands to work correctly
[[ ! -f /etc/wsl.conf ]] || source ~/.wslrc.zsh
[[ ! -f ~/.localrc.zsh ]] || source ~/.localrc.zsh
eval $(thefuck --alias)
[ -f /opt/miniconda3/etc/profile.d/conda.sh ] && source /opt/miniconda3/etc/profile.d/conda.sh