feat(hm): run fish if bash is started interactively #476

Merged
jalil merged 1 commit from push-mtxooyrqvkty into main 2025-05-13 19:20:33 +02:00
Showing only changes of commit c50d16b93f - Show all commits

View file

@ -50,6 +50,14 @@ in
}; };
programs = { programs = {
# Switch to fish if bash is started interactively
bash.initExtra = ''
if [[ $(${pkgs.procps}/bin/ps --no-header --pid=$PPID --format=comm) != "fish" && -z ''${BASH_EXECUTION_STRING} ]]
then
shopt -q login_shell && LOGIN_OPTION='--login' || LOGIN_OPTION=""
exec ${pkgs.fish}/bin/fish $LOGIN_OPTION
fi
'';
# Better cat (bat) # Better cat (bat)
bat = { bat = {
enable = true; enable = true;