From 1fe3bbeabf0d0206c4120cad05cc065cd01904cb Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Fri, 16 Dec 2016 18:32:44 -0500 Subject: [PATCH] shell/zsh: reorganize load/loadalls --- shell/zsh/.zshenv | 8 +++----- shell/zsh/.zshrc | 15 +++++++-------- 2 files changed, 10 insertions(+), 13 deletions(-) diff --git a/shell/zsh/.zshenv b/shell/zsh/.zshenv index 01c958c8..8ec33f44 100644 --- a/shell/zsh/.zshenv +++ b/shell/zsh/.zshenv @@ -1,14 +1,12 @@ -export DOTFILES="$HOME/.dotfiles" -source "$DOTFILES/shell/common.sh" +source "$HOME/.dotfiles/shell/common.sh" ## Paths # Ensure path arrays do not contain duplicates. typeset -gU cdpath fpath mailpath path - path=(/usr/local/{,s}bin $path) -load shell/env.sh -loadall shell/zsh env.zsh +load shell/zsh/config.zsh +loadall env.zsh path=( $HOME/.bin diff --git a/shell/zsh/.zshrc b/shell/zsh/.zshrc index 0801a2f7..6ed289a3 100644 --- a/shell/zsh/.zshrc +++ b/shell/zsh/.zshrc @@ -4,14 +4,6 @@ repo "tarjoilija/zgen" "$HOME/.zgen" -load shell/zsh/aliases.zsh -load shell/zsh/config.zsh -if is-interactive; then - load shell/zsh/completion.zsh - load shell/zsh/keybinds.zsh - load shell/zsh/prompt.zsh -fi - source "$HOME/.zgen/zgen.zsh" if ! zgen saved; then info "Creating zgen save" @@ -27,6 +19,13 @@ if ! zgen saved; then zgen save fi +if is-interactive; then + load shell/zsh/completion.zsh + load shell/zsh/keybinds.zsh + load shell/zsh/prompt.zsh +fi +loadall aliases.zsh + [[ -f "$HOME/.zshrc.local" ]] && source "$HOME/.zshrc.local" # Done!