gpt-3.5-turbo-1106· OpenAI
Arena Human Preference 55K
write a bash prompt that show the current git brach additionally in
- User
write a bash prompt that show the current git brach additionally in
- Assistant
You can add the current git branch to your bash prompt by editing your
PS1variable in your~/.bashrcor~/.bash_profilefile. Here's an example of how you can do that:export PS1="\[\e[1;34m\]\w\[\e[m\] \[\e[1;35m\]\$(git branch 2> /dev/null | grep -e '\* ' | sed 's/\* //')\[\e[m\] $ "This will show the current working directory followed by the current git branch in the bash prompt.
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.