Skip to content

Instantly share code, notes, and snippets.

@BlitzKraft
Created July 31, 2016 19:36
Show Gist options
  • Save BlitzKraft/e8620a3e65a6c7ac28ae7694ed28e4c0 to your computer and use it in GitHub Desktop.
Save BlitzKraft/e8620a3e65a6c7ac28ae7694ed28e4c0 to your computer and use it in GitHub Desktop.
Bash prompt with git branch and condensed directory paths
# Remove the comments
# The path is /usr/local/lib/python2.7/dist-packages/powerline/config_files/themes/shell/default_leftonly.json
{
"segments": {
"left": [
{
"function": "powerline.segments.common.net.hostname",
"priority": 10
},
{
"function": "powerline.segments.common.env.user",
"priority": 30
},
{
"function": "powerline.segments.common.env.virtualenv",
"priority": 50
},
{
"function": "powerline.segments.common.vcs.branch",
"priority": 40
},
{
"function": "powerline.segments.shell.cwd",
"args" : {
"dir_shorten_len" : 2
},
"priority": 10
},
{
"function": "powerline.segments.shell.jobnum",
"priority": 20
},
{
"function": "powerline.segments.shell.last_status",
"priority": 10
}
]
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment