1
0
Fork 0

enable direnv in bash and fix it for fish

This commit is contained in:
Pratham Patel 2023-09-22 05:29:50 +05:30
parent f350403320
commit 3a31a8427c
Signed by: thefossguy
SSH Key Fingerprint: SHA256:/B3wAg7jnMEBQ2JwkebbS/eXVZANDmqRfnd9QkIhxMI
2 changed files with 11 additions and 6 deletions

View File

@ -101,3 +101,8 @@ if command -v nvim > /dev/null; then
fi
PS1='[\u@\h \W]\$ '
# for direnv (should always be at the end)
if command -v direnv > /dev/null; then
eval "$(direnv hook bash)"
fi

View File

@ -47,12 +47,6 @@ if status is-interactive
set fish_greeting # disable the "new user" prompt
initial_fish_setup # call all "setup functions" here
# for direnv
if command -v direnv > /dev/null
set -g direnv_fish_mode disable_arrow
direnv hook fish | source
end
# git prompt options
# these are not in '/etc/nixos/configuration.nix' for following reasons
# - I use fish on macOS
@ -159,6 +153,12 @@ if status is-interactive
alias vvim="$(command -v vim)"
alias vim="$(command -v nvim)"
end
# for direnv (should always be at the end)
if command -v direnv > /dev/null
set -g direnv_fish_mode disable_arrow
direnv hook fish | source
end
end