fish: add custom prompt for ssh-agent as well as tmux
This commit is contained in:
parent
5218a83b2d
commit
16c8bb12b6
@ -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
|
||||
|
19
src/.config/fish/functions/extra_prompt.fish
Normal file
19
src/.config/fish/functions/extra_prompt.fish
Normal 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
|
@ -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
|
Loading…
Reference in New Issue
Block a user