Split always-on PATH/env, login hooks, and interactive UX into a managed tree under ~/.config/zsh, with never-overwrite local/ hooks. Agents and interactive shells share one PATH owner; deploy.sh applies the layout safely across machines.
21 lines
680 B
Bash
21 lines
680 B
Bash
# easyzsh stub: every zsh loads this. Keep it thin; logic lives under ~/.config/zsh/.
|
|
# Machine-local early env: ~/.config/zsh/local/env.local.zsh (never overwritten).
|
|
EASYZSH_HOME="${XDG_CONFIG_HOME:-$HOME/.config}/zsh"
|
|
|
|
if [[ -d "$EASYZSH_HOME/env" ]]; then
|
|
for _easyzsh_f in "$EASYZSH_HOME/env"/*.zsh(N); do
|
|
# shellcheck disable=SC1090
|
|
. "$_easyzsh_f"
|
|
done
|
|
unset _easyzsh_f
|
|
fi
|
|
|
|
if [[ -f "$EASYZSH_HOME/local/env.local.zsh" ]]; then
|
|
# shellcheck disable=SC1090
|
|
. "$EASYZSH_HOME/local/env.local.zsh"
|
|
elif [[ -f "$HOME/.config/zshenv.local" ]]; then
|
|
# Legacy path from earlier easyzsh layouts.
|
|
# shellcheck disable=SC1090
|
|
. "$HOME/.config/zshenv.local"
|
|
fi
|