fish: add custom prompt for ssh-agent as well as tmux

This commit is contained in:
dogeystamp 2022-07-06 11:56:09 -04:00
parent 5218a83b2d
commit 16c8bb12b6
Signed by: dogeystamp
GPG Key ID: 7225FE3592EFFA38
3 changed files with 20 additions and 13 deletions

View File

@ -4,7 +4,7 @@ end
source ~/.config/fish/aliases.fish
source ~/.config/fish/functions/tmux_prompt.fish
source ~/.config/fish/functions/extra_prompt.fish
# Set GPG_TTY
gpgt

View File

@ -0,0 +1,19 @@
# python venv style prompt replacement
if set -q TMUX
functions -c fish_prompt tmux_old_fish_prompt
function fish_prompt
printf "%s%s%s" (set_color 809C80) "(tmux) " (set_color normal)
tmux_old_fish_prompt
end
end
if set -q SSH_AGENT_PID
functions -c fish_prompt ssha_old_fish_prompt
function fish_prompt
printf "%s%s%s" (set_color 9C8080) "(ssha) " (set_color normal)
ssha_old_fish_prompt
end
end

View File

@ -1,12 +0,0 @@
if set -q TMUX
# python venv style prompt replacement
functions -c fish_prompt _old_fish_prompt
function fish_prompt
printf "%s%s%s" (set_color 809C80) "(tmux) " (set_color normal)
_old_fish_prompt
end
printf "aawagga"
end