Merge pull request #1481 from 1pav/theme-bira

Bira theme
pull/1484/head
Nils Winkler 2020-01-28 08:28:19 +01:00 committed by GitHub
commit eab3f6c469
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 30 additions and 0 deletions

View File

@ -0,0 +1,8 @@
# Bira
This is a port of Oh My Zsh's ['Bira'](https://github.com/ohmyzsh/ohmyzsh/blob/master/themes/bira.zsh-theme) theme. It looks the same as the original, except for the following changes:
- Exit code of last command is not shown
- More informative git prompt (if you want to keep it minimal, please read: https://github.com/Bash-it/bash-it#git-prompt)
- Position and colour of virtualenv prompt
- No ruby version prompt

View File

@ -0,0 +1,22 @@
#!/usr/bin/env bash
SCM_THEME_PROMPT_PREFIX=" ${yellow}"
SCM_THEME_PROMPT_SUFFIX="${reset_color}"
VIRTUALENV_THEME_PROMPT_PREFIX=" ${cyan}"
VIRTUALENV_THEME_PROMPT_SUFFIX="${reset_color}"
bold="\[\e[1m\]"
if [ ${UID} -eq 0 ]; then
user_host="${bold_red}\u@\h${normal}${reset_color}"
else
user_host="${bold_green}\u@\h${normal}${reset_color}"
fi
function prompt_command() {
local current_dir=" ${bold_blue}\w${normal}${reset_color}"
PS1="╭─${user_host}${current_dir}$(virtualenv_prompt)$(scm_prompt_info)\n╰─${bold}\\$ ${normal}"
}
safe_append_prompt_command prompt_command