gitbranch
It simply shows current branch name - or nothing if it isn’t a git repo.
sh cargo install gitbranch
sh gitbranch [<directory>]
Directory defaults to current working directory.