shell: launch zsh if we can
This commit is contained in:
parent
3d44475583
commit
b6ca38a4b5
3 changed files with 13 additions and 0 deletions
|
@ -75,6 +75,9 @@ if test -n "${ZSH_VERSION:-}"; then
|
|||
export NIX_BUILD_SHELL=zsh
|
||||
fi
|
||||
|
||||
# Launch zsh if we haven't yet
|
||||
LAUNCH_ZSH="${LAUNCH_ZSH:-true}"
|
||||
|
||||
# Basic default LS colors
|
||||
export LSCOLORS="Gxfxcxdxbxegedabagacad"
|
||||
|
||||
|
|
|
@ -13,3 +13,11 @@ if command -v zoxide > /dev/null 2>&1 || ${SKIP_ZOXIDE:-false}; then
|
|||
eval "$(zoxide init posix --hook prompt)"
|
||||
fi
|
||||
fi
|
||||
|
||||
# Switch to zsh if we're told to
|
||||
if [ "${LAUNCH_ZSH:-false}" = true ] && command -v zsh > /dev/null 2>&1; then
|
||||
LAUNCH_ZSH=false exec zsh
|
||||
fi
|
||||
|
||||
# terminal colorscheme
|
||||
careful_source "$SHELL_CONFIG_DIR/colors.sh"
|
||||
|
|
2
.zshrc
2
.zshrc
|
@ -265,6 +265,8 @@ load_working_dir && cd - > /dev/null || true
|
|||
# <<<
|
||||
# <<<
|
||||
|
||||
export BASH_LAUNCH_ZSH=false
|
||||
|
||||
# Optionally source another zshrc
|
||||
${SKIP_LOCAL_ZSHRC:-false} || careful_source "$SHELL_CONFIG_DIR/local/zshrc"
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue