{
"$type": "site.standard.document",
"path": "/git-status-in-your-bash-prompt/",
"publishedAt": "2017-03-22T21:56:15.000Z",
"site": "at://did:plc:6gssgguzeecdttuw4gpdshg2/site.standard.publication/self",
"tags": [
"coding",
"git",
"automation"
],
"textContent": "I'm a command line git user. I do 99% of my git related stuff without a GUI. I know the world is split about 50/50 between GUI users and command line users. But if you are like me, you'll love this post.\n\nAnytime you go to do any command with git, you'll start with git status. You have to know what branch you are one and what the local state of your repo is. I've been using bash-git-prompt for a while to provide this info without needing to type anything. You can check out the project here: https://github.com/magicmonty/bash-git-prompt\n\nInstalling\n\nInstallation is dead simple:\n\n[Code block]\n\nThen add this to your ~/.bash_profile:\n\n[Code block]\n\nMy customizations\n\nI'm not a huge fan of the default settings. So I added a few customizations to my setup. I disabled remote fetching to speed up the prompt. I prefer a single line for my prompt. I use stashes for work in progress code so I don't want my stash count included in the prompt.\n\nCustomizations added in ~/.bash_profile\n\n[Code block]\n\nThis leaves my prompt looking like: [Image: Screen-Shot-2017-03-22-at-5.54.21-PM.png]\n\nRead the original post with all embeds and interactive content at https://rants.broonix.ca/git-status-in-your-bash-prompt/",
"title": "Git status in your BASH prompt"
}