diff --git a/roles/setup/templates/zshrc.j2 b/roles/setup/templates/zshrc.j2 index f1df604..4877784 100644 --- a/roles/setup/templates/zshrc.j2 +++ b/roles/setup/templates/zshrc.j2 @@ -98,6 +98,12 @@ plugins=( # User configuration +# Set the XDG_CONFIG_HOME in this file +XDG_CONFIG_HOME=${XDG_CONFIG_HOME:=${HOME}/.config} + +# Source the env variables from the XDG_CONFIG_HOME +source $XDG_CONFIG_HOME/zsh/.zshenv + # export MANPATH="/usr/local/man:$MANPATH" # You may need to manually set your language environment @@ -122,8 +128,9 @@ plugins=( # alias zshconfig="mate ~/.zshrc" # alias ohmyzsh="mate ~/.oh-my-zsh" +# Custom aliases alias zshrc="nvim ~/.zshrc && source ~/.zshrc" -alias zshenv="nvim ~/.zshenv && source ~/.zshenv" +source $XDG_CONFIG_HOME/zsh/.aliases ZSH_CACHE_DIR=$HOME/.cache/oh-my-zsh if [[ ! -d $ZSH_CACHE_DIR ]]; then @@ -131,7 +138,7 @@ if [[ ! -d $ZSH_CACHE_DIR ]]; then fi source $ZSH/oh-my-zsh.sh -source $HOME/.zshenv + # For sharship rs loading eval "$(starship init zsh)"