Last active
February 24, 2018 07:52
-
-
Save u3u/1c27ea5f43813b37510dcf0b35102e30 to your computer and use it in GitHub Desktop.
~/.config/fish/functions/fish_title.fish
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function fish_title -d 'Use PROCESS $PWD format, replacing /Users/username with ~' | |
set realhome ~ | |
if test "$_" != "fish" | |
echo $_ '' | |
else | |
echo '' | |
end | |
string replace -r '^'"$realhome"'($|/)' '~$1' $PWD | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment