Skip to content

Instantly share code, notes, and snippets.

@brunurd
Created February 11, 2021 01:16
Show Gist options
  • Save brunurd/29ebe44d82803a35360c01cdef503662 to your computer and use it in GitHub Desktop.
Save brunurd/29ebe44d82803a35360c01cdef503662 to your computer and use it in GitHub Desktop.
fish prompt as git-bash in ~/.config/fish/
function fish_prompt
set -l git_branch (git branch ^/dev/null | sed -n '/\* /s///p')
echo -e '\033[0;32m'(whoami)'@'(hostname)' \033[0;33m'(prompt_pwd)' \033[0;36m('"$git_branch"')\033[0;00m\n$ '
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment