Autostart zsh

This commit is contained in:
Oshgnacknak 2025-09-10 17:30:15 +02:00
parent 07ae4e4d27
commit 024231c491
Signed by: Oshgnacknak
GPG key ID: 8CB7375654585956
3 changed files with 6 additions and 0 deletions

View file

@ -24,6 +24,10 @@ mkcd() {
cd "$1"
}
if [ "$PREFERRED_SHELL" = zsh ] && command -v ls > /dev/null; then
exec zsh
fi
export PS1="
$(tput bold)$(tput setaf 1)[$(tput setaf 3)\u$(tput setaf 2)@$(tput setaf 4)\H $(tput setaf 5)\w$(tput setaf 1)]$(tput setaf 7)
$ $(tput sgr0)"

1
_zshrc
View file

@ -30,6 +30,7 @@ function zle-keymap-select {
}
zle -N zle-keymap-select
unset PREFERRED_SHELL
[ -f "$HOME/./config/bashrc" ] && emulate sh -c "source $HOME/./config/bashrc"
[ -f "$HOME/.bashrc" ] && emulate sh -c "source $HOME/.bashrc"

View file

@ -114,6 +114,7 @@
# Environment variables only for this user/session
home.sessionVariables = {
EDITOR = "nvim";
PREFERRED_SHELL = "zsh";
};
# Good HM hygiene