mirror of
https://github.com/ohmybash/oh-my-bash.git
synced 2024-05-11 05:55:37 +00:00
lib, themes: Resolve conflicting variables
"lib" has used the variables "red", "green", "yellow", "blue", and "purple" for outputting logs to stdout/stderr. On the other hand, "themes" has used the same variables for including escape sequences in PS1. These two sets of variables have different values, i.e., the latter is enclosed by '\[' and '\]' and contains escaped '\e', which means that there have been variable conflicts. In this commit, more specific variables are used in these places to resolve the conflicts.
This commit is contained in:
14
lib/base.sh
14
lib/base.sh
@@ -214,14 +214,14 @@ bigfind() {
|
||||
# ii: display useful host related informaton
|
||||
# -------------------------------------------------------------------
|
||||
ii() {
|
||||
echo -e "\\nYou are logged on ${red}$HOST"
|
||||
echo -e "\\nYou are logged on ${_omb_term_red}$HOST"
|
||||
echo -e "\\nAdditionnal information:$NC " ; uname -a
|
||||
echo -e "\\n${red}Users logged on:$NC " ; w -h
|
||||
echo -e "\\n${red}Current date :$NC " ; date
|
||||
echo -e "\\n${red}Machine stats :$NC " ; uptime
|
||||
[[ "$OSTYPE" == darwin* ]] && echo -e "\\n${red}Current network location :$NC " ; scselect
|
||||
echo -e "\\n${red}Public facing IP Address :$NC " ;myip
|
||||
[[ "$OSTYPE" == darwin* ]] && echo -e "\\n${red}DNS Configuration:$NC " ; scutil --dns
|
||||
echo -e "\\n${_omb_term_red}Users logged on:$NC " ; w -h
|
||||
echo -e "\\n${_omb_term_red}Current date :$NC " ; date
|
||||
echo -e "\\n${_omb_term_red}Machine stats :$NC " ; uptime
|
||||
[[ "$OSTYPE" == darwin* ]] && echo -e "\\n${_omb_term_red}Current network location :$NC " ; scselect
|
||||
echo -e "\\n${_omb_term_red}Public facing IP Address :$NC " ;myip
|
||||
[[ "$OSTYPE" == darwin* ]] && echo -e "\\n${_omb_term_red}DNS Configuration:$NC " ; scutil --dns
|
||||
echo
|
||||
}
|
||||
|
||||
|
||||
@@ -160,14 +160,14 @@ fi
|
||||
#
|
||||
# Headers and Logging
|
||||
#
|
||||
_omb_log_header() { printf "\n${_omb_term_bold}${purple}========== %s ==========${_omb_term_reset}\n" "$@"; }
|
||||
_omb_log_header() { printf "\n${_omb_term_bold}${_omb_term_magenta}========== %s ==========${_omb_term_reset}\n" "$@"; }
|
||||
_omb_log_arrow() { printf "➜ %s\n" "$@"; }
|
||||
_omb_log_success() { printf "${green}✔ %s${_omb_term_reset}\n" "$@"; }
|
||||
_omb_log_error() { printf "${red}✖ %s${_omb_term_reset}\n" "$@"; }
|
||||
_omb_log_success() { printf "${_omb_term_green}✔ %s${_omb_term_reset}\n" "$@"; }
|
||||
_omb_log_error() { printf "${_omb_term_red}✖ %s${_omb_term_reset}\n" "$@"; }
|
||||
_omb_log_warning() { printf "${_omb_term_yellow}➜ %s${_omb_term_reset}\n" "$@"; }
|
||||
_omb_log_underline() { printf "${_omb_term_underline}${_omb_term_bold}%s${_omb_term_reset}\n" "$@"; }
|
||||
_omb_log_bold() { printf "${_omb_term_bold}%s${_omb_term_reset}\n" "$@"; }
|
||||
_omb_log_note() { printf "${_omb_term_underline}${_omb_term_bold}${blue}Note:${_omb_term_reset} ${yellow}%s${_omb_term_reset}\n" "$@"; }
|
||||
_omb_log_note() { printf "${_omb_term_underline}${_omb_term_bold}${_omb_term_blue}Note:${_omb_term_reset} ${_omb_term_yellow}%s${_omb_term_reset}\n" "$@"; }
|
||||
|
||||
#
|
||||
# USAGE FOR SEEKING CONFIRMATION
|
||||
|
||||
@@ -138,9 +138,9 @@ battery_charge(){
|
||||
# Depleted char
|
||||
local D_C='▹'
|
||||
local DEPLETED_COLOR="${_omb_prompt_normal}"
|
||||
local FULL_COLOR="${green}"
|
||||
local HALF_COLOR="${yellow}"
|
||||
local DANGER_COLOR="${red}"
|
||||
local FULL_COLOR="${_omb_prompt_green}"
|
||||
local HALF_COLOR="${_omb_prompt_yellow}"
|
||||
local DANGER_COLOR="${_omb_prompt_red}"
|
||||
local BATTERY_OUTPUT="${DEPLETED_COLOR}${D_C}${D_C}${D_C}${D_C}${D_C}"
|
||||
local BATTERY_PERC=$(battery_percentage)
|
||||
|
||||
|
||||
@@ -1,17 +1,17 @@
|
||||
#! bash oh-my-bash.module
|
||||
SCM_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
SCM_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${_omb_prompt_bold_green}✓"
|
||||
SCM_THEME_PROMPT_PREFIX=" |"
|
||||
SCM_THEME_PROMPT_SUFFIX="${green}|"
|
||||
SCM_THEME_PROMPT_SUFFIX="${_omb_prompt_green}|"
|
||||
|
||||
GIT_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
GIT_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
GIT_THEME_PROMPT_CLEAN=" ${_omb_prompt_bold_green}✓"
|
||||
GIT_THEME_PROMPT_PREFIX=" ${green}|"
|
||||
GIT_THEME_PROMPT_SUFFIX="${green}|"
|
||||
GIT_THEME_PROMPT_PREFIX=" ${_omb_prompt_green}|"
|
||||
GIT_THEME_PROMPT_SUFFIX="${_omb_prompt_green}|"
|
||||
|
||||
# Nicely formatted terminal prompt
|
||||
function _omb_theme_PROMPT_COMMAND(){
|
||||
export PS1="\n${_omb_prompt_bold_black}[${blue}\@${_omb_prompt_bold_black}]-${_omb_prompt_bold_black}[${green}\u${yellow}@${green}\h${_omb_prompt_bold_black}]-${_omb_prompt_bold_black}[${purple}\w${_omb_prompt_bold_black}]-$(scm_prompt_info)\n${_omb_prompt_reset_color}\$ "
|
||||
export PS1="\n${_omb_prompt_bold_black}[${_omb_prompt_blue}\@${_omb_prompt_bold_black}]-${_omb_prompt_bold_black}[${_omb_prompt_green}\u${_omb_prompt_yellow}@${_omb_prompt_green}\h${_omb_prompt_bold_black}]-${_omb_prompt_bold_black}[${_omb_prompt_magenta}\w${_omb_prompt_bold_black}]-$(scm_prompt_info)\n${_omb_prompt_reset_color}\$ "
|
||||
}
|
||||
|
||||
_omb_util_add_prompt_command _omb_theme_PROMPT_COMMAND
|
||||
|
||||
@@ -1,22 +1,22 @@
|
||||
#! bash oh-my-bash.module
|
||||
SCM_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
SCM_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${_omb_prompt_bold_green}✓"
|
||||
SCM_THEME_PROMPT_PREFIX=" |"
|
||||
SCM_THEME_PROMPT_SUFFIX="${green}|"
|
||||
SCM_THEME_PROMPT_SUFFIX="${_omb_prompt_green}|"
|
||||
|
||||
GIT_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
GIT_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
GIT_THEME_PROMPT_CLEAN=" ${_omb_prompt_bold_green}✓"
|
||||
GIT_THEME_PROMPT_PREFIX=" ${green}|"
|
||||
GIT_THEME_PROMPT_SUFFIX="${green}|"
|
||||
GIT_THEME_PROMPT_PREFIX=" ${_omb_prompt_green}|"
|
||||
GIT_THEME_PROMPT_SUFFIX="${_omb_prompt_green}|"
|
||||
|
||||
RVM_THEME_PROMPT_PREFIX="|"
|
||||
RVM_THEME_PROMPT_SUFFIX="|"
|
||||
|
||||
function _omb_theme_PROMPT_COMMAND() {
|
||||
#PS1="${_omb_prompt_bold_cyan}$(scm_char)${green}$(scm_prompt_info)${purple}$(_omb_prompt_print_ruby_env) ${yellow}\h ${_omb_prompt_reset_color}in ${green}\w ${_omb_prompt_reset_color}\n${green}→${_omb_prompt_reset_color} "
|
||||
#PS1="\n${purple}\h: ${_omb_prompt_reset_color} ${green}\w\n${_omb_prompt_bold_cyan}$(scm_char)${green}$(scm_prompt_info) ${green}→${_omb_prompt_reset_color} "
|
||||
#PS1="\n${_omb_prompt_cyan}\h: ${_omb_prompt_reset_color} ${yellow}\w\n${red}$(scm_char)${red}$(scm_prompt_info) ${green}→${_omb_prompt_reset_color} "
|
||||
PS1="\n${_omb_prompt_cyan}\h: ${_omb_prompt_reset_color} ${yellow}\w ${green}$(scm_prompt_info)\n${_omb_prompt_reset_color}→ "
|
||||
#PS1="${_omb_prompt_bold_cyan}$(scm_char)${_omb_prompt_green}$(scm_prompt_info)${_omb_prompt_magenta}$(_omb_prompt_print_ruby_env) ${_omb_prompt_yellow}\h ${_omb_prompt_reset_color}in ${_omb_prompt_green}\w ${_omb_prompt_reset_color}\n${_omb_prompt_green}→${_omb_prompt_reset_color} "
|
||||
#PS1="\n${_omb_prompt_magenta}\h: ${_omb_prompt_reset_color} ${_omb_prompt_green}\w\n${_omb_prompt_bold_cyan}$(scm_char)${_omb_prompt_green}$(scm_prompt_info) ${_omb_prompt_green}→${_omb_prompt_reset_color} "
|
||||
#PS1="\n${_omb_prompt_cyan}\h: ${_omb_prompt_reset_color} ${_omb_prompt_yellow}\w\n${_omb_prompt_red}$(scm_char)${_omb_prompt_red}$(scm_prompt_info) ${_omb_prompt_green}→${_omb_prompt_reset_color} "
|
||||
PS1="\n${_omb_prompt_cyan}\h: ${_omb_prompt_reset_color} ${_omb_prompt_yellow}\w ${_omb_prompt_green}$(scm_prompt_info)\n${_omb_prompt_reset_color}→ "
|
||||
}
|
||||
|
||||
_omb_util_add_prompt_command _omb_theme_PROMPT_COMMAND
|
||||
|
||||
@@ -30,7 +30,7 @@ function set_host_color() {
|
||||
function set_user_color() {
|
||||
case $(id -u) in
|
||||
0)
|
||||
printf "${red}"
|
||||
printf "${_omb_prompt_red}"
|
||||
;;
|
||||
*)
|
||||
printf "${_omb_prompt_cyan}"
|
||||
@@ -73,7 +73,7 @@ function _omb_theme_PROMPT_COMMAND() {
|
||||
ps_uh_separator="${dark_grey}@${_omb_prompt_normal}"
|
||||
ps_hostname="$(set_host_color)\h${_omb_prompt_normal}"
|
||||
|
||||
ps_path="${yellow}\w${_omb_prompt_normal}"
|
||||
ps_path="${_omb_prompt_yellow}\w${_omb_prompt_normal}"
|
||||
ps_scm_prompt="${light_grey}$(scm_prompt)"
|
||||
|
||||
ps_user_mark="${_omb_prompt_normal} ${_omb_prompt_normal}"
|
||||
@@ -93,8 +93,8 @@ SCM_THEME_PROMPT_PREFIX=""
|
||||
SCM_THEME_PROMPT_SUFFIX=""
|
||||
|
||||
SCM_THEME_PROMPT_DIRTY=" ${_omb_prompt_bold_red}✗${light_grey}"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${green}✓${light_grey}"
|
||||
SCM_GIT_CHAR="${green}±${light_grey}"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${_omb_prompt_green}✓${light_grey}"
|
||||
SCM_GIT_CHAR="${_omb_prompt_green}±${light_grey}"
|
||||
SCM_SVN_CHAR="${_omb_prompt_bold_cyan}⑆${light_grey}"
|
||||
SCM_HG_CHAR="${_omb_prompt_bold_red}☿${light_grey}"
|
||||
|
||||
|
||||
@@ -1,19 +1,19 @@
|
||||
#! bash oh-my-bash.module
|
||||
SCM_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
SCM_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${_omb_prompt_bold_green}✓"
|
||||
SCM_THEME_PROMPT_PREFIX=" |"
|
||||
SCM_THEME_PROMPT_SUFFIX="${green}|"
|
||||
SCM_THEME_PROMPT_SUFFIX="${_omb_prompt_green}|"
|
||||
|
||||
GIT_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
GIT_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
GIT_THEME_PROMPT_CLEAN=" ${_omb_prompt_bold_green}✓"
|
||||
GIT_THEME_PROMPT_PREFIX=" ${green}|"
|
||||
GIT_THEME_PROMPT_SUFFIX="${green}|"
|
||||
GIT_THEME_PROMPT_PREFIX=" ${_omb_prompt_green}|"
|
||||
GIT_THEME_PROMPT_SUFFIX="${_omb_prompt_green}|"
|
||||
|
||||
CONDAENV_THEME_PROMPT_SUFFIX="|"
|
||||
|
||||
function _omb_theme_PROMPT_COMMAND() {
|
||||
#PS1="${_omb_prompt_bold_cyan}$(scm_char)${green}$(scm_prompt_info)${purple}$(_omb_prompt_print_ruby_env) ${yellow}\h ${_omb_prompt_reset_color}in ${green}\w ${_omb_prompt_reset_color}\n${green}→${_omb_prompt_reset_color} "
|
||||
PS1="\n${yellow}$(python_version_prompt) ${purple}\h ${_omb_prompt_reset_color}in ${green}\w\n${_omb_prompt_bold_cyan}$(scm_char)${green}$(scm_prompt_info) ${green}→${_omb_prompt_reset_color} "
|
||||
#PS1="${_omb_prompt_bold_cyan}$(scm_char)${_omb_prompt_green}$(scm_prompt_info)${_omb_prompt_magenta}$(_omb_prompt_print_ruby_env) ${_omb_prompt_yellow}\h ${_omb_prompt_reset_color}in ${_omb_prompt_green}\w ${_omb_prompt_reset_color}\n${_omb_prompt_green}→${_omb_prompt_reset_color} "
|
||||
PS1="\n${_omb_prompt_yellow}$(python_version_prompt) ${_omb_prompt_magenta}\h ${_omb_prompt_reset_color}in ${_omb_prompt_green}\w\n${_omb_prompt_bold_cyan}$(scm_char)${_omb_prompt_green}$(scm_prompt_info) ${_omb_prompt_green}→${_omb_prompt_reset_color} "
|
||||
}
|
||||
|
||||
_omb_util_add_prompt_command _omb_theme_PROMPT_COMMAND
|
||||
|
||||
@@ -1,14 +1,14 @@
|
||||
#! bash oh-my-bash.module
|
||||
|
||||
SCM_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
SCM_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${_omb_prompt_bold_green}✓"
|
||||
SCM_THEME_PROMPT_PREFIX=" ${green}|"
|
||||
SCM_THEME_PROMPT_SUFFIX="${green}|"
|
||||
SCM_THEME_PROMPT_PREFIX=" ${_omb_prompt_green}|"
|
||||
SCM_THEME_PROMPT_SUFFIX="${_omb_prompt_green}|"
|
||||
|
||||
GIT_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
GIT_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
GIT_THEME_PROMPT_CLEAN=" ${_omb_prompt_bold_green}✓"
|
||||
GIT_THEME_PROMPT_PREFIX=" ${green}|"
|
||||
GIT_THEME_PROMPT_SUFFIX="${green}|"
|
||||
GIT_THEME_PROMPT_PREFIX=" ${_omb_prompt_green}|"
|
||||
GIT_THEME_PROMPT_SUFFIX="${_omb_prompt_green}|"
|
||||
|
||||
RVM_THEME_PROMPT_PREFIX="|"
|
||||
RVM_THEME_PROMPT_SUFFIX="|"
|
||||
@@ -22,12 +22,12 @@ __bobby_clock() {
|
||||
}
|
||||
|
||||
function _omb_theme_PROMPT_COMMAND() {
|
||||
#PS1="${_omb_prompt_bold_cyan}$(scm_char)${green}$(scm_prompt_info)${purple}$(_omb_prompt_print_ruby_env) ${yellow}\h ${_omb_prompt_reset_color}in ${green}\w ${_omb_prompt_reset_color}\n${green}→${_omb_prompt_reset_color} "
|
||||
PS1="\n$(battery_char) $(__bobby_clock)${yellow}$(_omb_prompt_print_ruby_env) ${purple}\h ${_omb_prompt_reset_color}in ${green}\w\n${_omb_prompt_bold_cyan}$(scm_prompt_char_info) ${green}→${_omb_prompt_reset_color} "
|
||||
#PS1="${_omb_prompt_bold_cyan}$(scm_char)${_omb_prompt_green}$(scm_prompt_info)${_omb_prompt_magenta}$(_omb_prompt_print_ruby_env) ${_omb_prompt_yellow}\h ${_omb_prompt_reset_color}in ${_omb_prompt_green}\w ${_omb_prompt_reset_color}\n${_omb_prompt_green}→${_omb_prompt_reset_color} "
|
||||
PS1="\n$(battery_char) $(__bobby_clock)${_omb_prompt_yellow}$(_omb_prompt_print_ruby_env) ${_omb_prompt_magenta}\h ${_omb_prompt_reset_color}in ${_omb_prompt_green}\w\n${_omb_prompt_bold_cyan}$(scm_prompt_char_info) ${_omb_prompt_green}→${_omb_prompt_reset_color} "
|
||||
}
|
||||
|
||||
THEME_SHOW_CLOCK_CHAR=${THEME_SHOW_CLOCK_CHAR:-"true"}
|
||||
THEME_CLOCK_CHAR_COLOR=${THEME_CLOCK_CHAR_COLOR:-"$red"}
|
||||
THEME_CLOCK_CHAR_COLOR=${THEME_CLOCK_CHAR_COLOR:-"$_omb_prompt_red"}
|
||||
THEME_CLOCK_COLOR=${THEME_CLOCK_COLOR:-"$_omb_prompt_bold_cyan"}
|
||||
THEME_CLOCK_FORMAT=${THEME_CLOCK_FORMAT:-"%Y-%m-%d %H:%M:%S"}
|
||||
|
||||
|
||||
@@ -27,10 +27,10 @@ scm_prompt() {
|
||||
}
|
||||
|
||||
_omb_theme_PROMPT_COMMAND() {
|
||||
PS1="${_omb_prompt_white}${_omb_prompt_background_blue} \u${_omb_prompt_normal}${_omb_prompt_background_blue}@${red}${_omb_prompt_background_blue}\h $(clock_prompt) ${_omb_prompt_reset_color}${_omb_prompt_normal} $(battery_charge)\n${_omb_prompt_bold_black}${_omb_prompt_background_white} \w ${_omb_prompt_normal}$(scm_prompt)$(is_vim_shell)\n${_omb_prompt_white}>${_omb_prompt_normal} "
|
||||
PS1="${_omb_prompt_white}${_omb_prompt_background_blue} \u${_omb_prompt_normal}${_omb_prompt_background_blue}@${_omb_prompt_red}${_omb_prompt_background_blue}\h $(clock_prompt) ${_omb_prompt_reset_color}${_omb_prompt_normal} $(battery_charge)\n${_omb_prompt_bold_black}${_omb_prompt_background_white} \w ${_omb_prompt_normal}$(scm_prompt)$(is_vim_shell)\n${_omb_prompt_white}>${_omb_prompt_normal} "
|
||||
}
|
||||
|
||||
THEME_CLOCK_COLOR=${THEME_CLOCK_COLOR:-"$blue$_omb_prompt_background_white"}
|
||||
THEME_CLOCK_COLOR=${THEME_CLOCK_COLOR:-"$_omb_prompt_blue$_omb_prompt_background_white"}
|
||||
THEME_CLOCK_FORMAT=${THEME_CLOCK_FORMAT:-" %H:%M:%S"}
|
||||
|
||||
_omb_util_add_prompt_command _omb_theme_PROMPT_COMMAND
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
#! bash oh-my-bash.module
|
||||
|
||||
function _omb_theme_PROMPT_COMMAND() {
|
||||
PS1="${green}\u@\h $(clock_prompt) ${_omb_prompt_reset_color}${_omb_prompt_white}\w${_omb_prompt_reset_color}$(scm_prompt_info)${blue} →${_omb_prompt_bold_blue} ${_omb_prompt_reset_color} ";
|
||||
PS1="${_omb_prompt_green}\u@\h $(clock_prompt) ${_omb_prompt_reset_color}${_omb_prompt_white}\w${_omb_prompt_reset_color}$(scm_prompt_info)${_omb_prompt_blue} →${_omb_prompt_bold_blue} ${_omb_prompt_reset_color} ";
|
||||
}
|
||||
|
||||
THEME_CLOCK_COLOR=${THEME_CLOCK_COLOR:-"$blue"}
|
||||
THEME_CLOCK_COLOR=${THEME_CLOCK_COLOR:-"$_omb_prompt_blue"}
|
||||
THEME_CLOCK_FORMAT=${THEME_CLOCK_FORMAT:-"%I:%M:%S"}
|
||||
|
||||
_omb_util_add_prompt_command _omb_theme_PROMPT_COMMAND
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
#! bash oh-my-bash.module
|
||||
# git theming
|
||||
ZSH_THEME_GIT_PROMPT_PREFIX="${_omb_prompt_bold_blue}(${yellow}%B"
|
||||
ZSH_THEME_GIT_PROMPT_PREFIX="${_omb_prompt_bold_blue}(${_omb_prompt_yellow}%B"
|
||||
ZSH_THEME_GIT_PROMPT_SUFFIX="%b${_omb_prompt_bold_blue})${_omb_prompt_reset_color} "
|
||||
ZSH_THEME_GIT_PROMPT_CLEAN=""
|
||||
ZSH_THEME_GIT_PROMPT_DIRTY="${_omb_prompt_bold_red}✗"
|
||||
@@ -12,9 +12,9 @@ export LS_COLORS='no=00:fi=00:di=01;34:ln=00;36:pi=40;33:so=01;35:do=01;35:bd=40
|
||||
|
||||
function _omb_theme_PROMPT_COMMAND() {
|
||||
|
||||
if [ "$(whoami)" = root ]; then no_color=$red; else no_color=$_omb_prompt_white; fi
|
||||
if [ "$(whoami)" = root ]; then no_color=$_omb_prompt_red; else no_color=$_omb_prompt_white; fi
|
||||
|
||||
PS1="${no_color}\u${_omb_prompt_reset_color}:${blue}\W/${_omb_prompt_reset_color} \[\$(scm_prompt_info)\]$ "
|
||||
PS1="${no_color}\u${_omb_prompt_reset_color}:${_omb_prompt_blue}\W/${_omb_prompt_reset_color} \[\$(scm_prompt_info)\]$ "
|
||||
RPROMPT='[\t]'
|
||||
}
|
||||
|
||||
|
||||
@@ -5,12 +5,12 @@
|
||||
# BASED ON: Mr Briggs by Matt Brigg (matt@mattbriggs.net) #
|
||||
# ------------------------------------------------------------------#
|
||||
|
||||
SCM_THEME_PROMPT_DIRTY="${red} ✗${_omb_prompt_reset_color}"
|
||||
SCM_THEME_PROMPT_AHEAD="${yellow} ↑${_omb_prompt_reset_color}"
|
||||
SCM_THEME_PROMPT_CLEAN="${green} ✓${_omb_prompt_reset_color}"
|
||||
SCM_THEME_PROMPT_DIRTY="${_omb_prompt_red} ✗${_omb_prompt_reset_color}"
|
||||
SCM_THEME_PROMPT_AHEAD="${_omb_prompt_yellow} ↑${_omb_prompt_reset_color}"
|
||||
SCM_THEME_PROMPT_CLEAN="${_omb_prompt_green} ✓${_omb_prompt_reset_color}"
|
||||
SCM_THEME_PROMPT_PREFIX=" "
|
||||
SCM_THEME_PROMPT_SUFFIX=""
|
||||
GIT_SHA_PREFIX="${blue}"
|
||||
GIT_SHA_PREFIX="${_omb_prompt_blue}"
|
||||
GIT_SHA_SUFFIX="${_omb_prompt_reset_color}"
|
||||
|
||||
function git_short_sha() {
|
||||
@@ -19,11 +19,11 @@ function git_short_sha() {
|
||||
|
||||
function _omb_theme_PROMPT_COMMAND() {
|
||||
local return_status=""
|
||||
local ruby="${red}$(_omb_prompt_print_ruby_env)${_omb_prompt_reset_color}"
|
||||
local user_host="${green}\h @ \w${_omb_prompt_reset_color}"
|
||||
local ruby="${_omb_prompt_red}$(_omb_prompt_print_ruby_env)${_omb_prompt_reset_color}"
|
||||
local user_host="${_omb_prompt_green}\h @ \w${_omb_prompt_reset_color}"
|
||||
local git_branch="$(git_short_sha)${_omb_prompt_cyan}$(scm_prompt_info)${_omb_prompt_reset_color}"
|
||||
local prompt_symbol=' '
|
||||
local prompt_char="${purple}>_${_omb_prompt_reset_color} "
|
||||
local prompt_char="${_omb_prompt_magenta}>_${_omb_prompt_reset_color} "
|
||||
|
||||
PS1="\n${user_host}${prompt_symbol}${ruby} ${git_branch} ${return_status}\n${prompt_char}"
|
||||
}
|
||||
|
||||
@@ -19,7 +19,7 @@ VIRTUALENV_THEME_PROMPT_SUFFIX=""
|
||||
# SCM prompts
|
||||
SCM_NONE_CHAR=""
|
||||
SCM_GIT_CHAR="[±] "
|
||||
SCM_GIT_BEHIND_CHAR="${red}↓${_omb_prompt_normal}"
|
||||
SCM_GIT_BEHIND_CHAR="${_omb_prompt_red}↓${_omb_prompt_normal}"
|
||||
SCM_GIT_AHEAD_CHAR="${_omb_prompt_bold_green}↑${_omb_prompt_normal}"
|
||||
SCM_GIT_UNTRACKED_CHAR="⌀"
|
||||
SCM_GIT_UNSTAGED_CHAR="${_omb_prompt_bold_yellow}•${_omb_prompt_normal}"
|
||||
@@ -31,7 +31,7 @@ SCM_THEME_PROMPT_PREFIX=""
|
||||
SCM_THEME_PROMPT_SUFFIX=""
|
||||
|
||||
# Git status prompts
|
||||
GIT_THEME_PROMPT_DIRTY=" ${red}✗${_omb_prompt_normal}"
|
||||
GIT_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗${_omb_prompt_normal}"
|
||||
GIT_THEME_PROMPT_CLEAN=" ${_omb_prompt_bold_green}✓${_omb_prompt_normal}"
|
||||
GIT_THEME_PROMPT_PREFIX=""
|
||||
GIT_THEME_PROMPT_SUFFIX=""
|
||||
|
||||
@@ -35,14 +35,14 @@
|
||||
# ----------------------------------------------------------------- COLOR CONF
|
||||
D_DEFAULT_COLOR="${_omb_prompt_normal}"
|
||||
D_INTERMEDIATE_COLOR="${_omb_prompt_white}"
|
||||
D_USER_COLOR="${purple}"
|
||||
D_SUPERUSER_COLOR="${red}"
|
||||
D_USER_COLOR="${_omb_prompt_magenta}"
|
||||
D_SUPERUSER_COLOR="${_omb_prompt_red}"
|
||||
D_MACHINE_COLOR="${_omb_prompt_cyan}"
|
||||
D_DIR_COLOR="${green}"
|
||||
D_SCM_COLOR="${yellow}"
|
||||
D_BRANCH_COLOR="${yellow}"
|
||||
D_DIR_COLOR="${_omb_prompt_green}"
|
||||
D_SCM_COLOR="${_omb_prompt_yellow}"
|
||||
D_BRANCH_COLOR="${_omb_prompt_yellow}"
|
||||
D_CHANGES_COLOR="${_omb_prompt_white}"
|
||||
D_CMDFAIL_COLOR="${red}"
|
||||
D_CMDFAIL_COLOR="${_omb_prompt_red}"
|
||||
D_VIMSHELL_COLOR="${_omb_prompt_cyan}"
|
||||
|
||||
# ------------------------------------------------------------------ FUNCTIONS
|
||||
|
||||
@@ -10,14 +10,14 @@ SCM_THEME_PROMPT_SUFFIX=""
|
||||
if [ ! -z $RVM_THEME_PROMPT_COLOR ]; then
|
||||
RVM_THEME_PROMPT_COLOR=$(eval echo $`echo ${RVM_THEME_PROMPT_COLOR}`);
|
||||
else
|
||||
RVM_THEME_PROMPT_COLOR="${red}"
|
||||
RVM_THEME_PROMPT_COLOR="${_omb_prompt_red}"
|
||||
fi
|
||||
RVM_THEME_PROMPT_PREFIX="(${RVM_THEME_PROMPT_COLOR}rb${_omb_prompt_normal}: "
|
||||
RVM_THEME_PROMPT_SUFFIX=") "
|
||||
if [ ! -z $VIRTUALENV_THEME_PROMPT_COLOR ]; then
|
||||
VIRTUALENV_THEME_PROMPT_COLOR=$(eval echo $`echo ${VIRTUALENV_THEME_PROMPT_COLOR}`);
|
||||
else
|
||||
VIRTUALENV_THEME_PROMPT_COLOR="${green}"
|
||||
VIRTUALENV_THEME_PROMPT_COLOR="${_omb_prompt_green}"
|
||||
fi
|
||||
VIRTUALENV_THEME_PROMPT_PREFIX="(${VIRTUALENV_THEME_PROMPT_COLOR}py${_omb_prompt_normal}: "
|
||||
VIRTUALENV_THEME_PROMPT_SUFFIX=") "
|
||||
@@ -25,7 +25,7 @@ VIRTUALENV_THEME_PROMPT_SUFFIX=") "
|
||||
if [ ! -z $THEME_PROMPT_HOST_COLOR ]; then
|
||||
THEME_PROMPT_HOST_COLOR=$(eval echo $`echo ${THEME_PROMPT_HOST_COLOR}`);
|
||||
else
|
||||
THEME_PROMPT_HOST_COLOR="$blue"
|
||||
THEME_PROMPT_HOST_COLOR="$_omb_prompt_blue"
|
||||
fi
|
||||
|
||||
doubletime_scm_prompt() {
|
||||
@@ -63,7 +63,7 @@ git_prompt_status() {
|
||||
elif [ -n "$(echo $git_status_output | grep 'Untracked files')" ]; then
|
||||
git_status="${_omb_prompt_bold_cyan}$(scm_prompt_info) +"
|
||||
elif [ -n "$(echo $git_status_output | grep 'nothing to commit')" ]; then
|
||||
git_status="${_omb_prompt_bold_green}$(scm_prompt_info) ${green}✓"
|
||||
git_status="${_omb_prompt_bold_green}$(scm_prompt_info) ${_omb_prompt_green}✓"
|
||||
else
|
||||
git_status="$(scm_prompt_info)"
|
||||
fi
|
||||
|
||||
@@ -25,7 +25,7 @@ dulcie_background() {
|
||||
|
||||
_omb_theme_PROMPT_COMMAND() {
|
||||
color_user_root=$(dulcie_color 169)
|
||||
color_user_nonroot="${green}"
|
||||
color_user_nonroot="${_omb_prompt_green}"
|
||||
color_host_local=$(dulcie_color 230)
|
||||
color_host_remote=$(dulcie_color 214)
|
||||
color_rootdir=$(dulcie_color 117)
|
||||
@@ -53,7 +53,7 @@ _omb_theme_PROMPT_COMMAND() {
|
||||
DULCIE_WORKINGDIR="${color_workingdir}\W${_omb_prompt_reset_color}"
|
||||
DULCIE_PROMPTCHAR="${color_user}"'\$'"${_omb_prompt_reset_color}"
|
||||
|
||||
SCM_THEME_PROMPT_DIRTY=" ${red}✗${_omb_prompt_reset_color}"
|
||||
SCM_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗${_omb_prompt_reset_color}"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${_omb_prompt_bold_green}✓${_omb_prompt_normal}"
|
||||
DULCIE_SCM_BACKGROUND="${background_scm}"
|
||||
DULCIE_SCM_DIR_COLOR="${color_rootdir}"
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
#! bash oh-my-bash.module
|
||||
|
||||
SCM_THEME_PROMPT_PREFIX="${_omb_prompt_cyan} on ${green}"
|
||||
SCM_THEME_PROMPT_PREFIX="${_omb_prompt_cyan} on ${_omb_prompt_green}"
|
||||
SCM_THEME_PROMPT_SUFFIX=""
|
||||
SCM_THEME_PROMPT_DIRTY=" ${red}with changes"
|
||||
SCM_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}with changes"
|
||||
SCM_THEME_PROMPT_CLEAN=""
|
||||
|
||||
venv() {
|
||||
@@ -18,7 +18,7 @@ last_two_dirs() {
|
||||
}
|
||||
|
||||
_omb_theme_PROMPT_COMMAND() {
|
||||
PS1="${yellow}# ${_omb_prompt_reset_color}$(last_two_dirs)$(scm_prompt_info)${_omb_prompt_reset_color}$(venv)${_omb_prompt_reset_color} ${_omb_prompt_cyan}\n> ${_omb_prompt_reset_color}"
|
||||
PS1="${_omb_prompt_yellow}# ${_omb_prompt_reset_color}$(last_two_dirs)$(scm_prompt_info)${_omb_prompt_reset_color}$(venv)${_omb_prompt_reset_color} ${_omb_prompt_cyan}\n> ${_omb_prompt_reset_color}"
|
||||
}
|
||||
|
||||
_omb_util_add_prompt_command _omb_theme_PROMPT_COMMAND
|
||||
|
||||
@@ -1,29 +1,29 @@
|
||||
#! bash oh-my-bash.module
|
||||
|
||||
SCM_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
SCM_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${_omb_prompt_bold_green}✓"
|
||||
SCM_THEME_PROMPT_PREFIX=" |"
|
||||
SCM_THEME_PROMPT_SUFFIX="${green}|"
|
||||
SCM_THEME_PROMPT_SUFFIX="${_omb_prompt_green}|"
|
||||
|
||||
GIT_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
GIT_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
GIT_THEME_PROMPT_CLEAN=" ${_omb_prompt_bold_green}✓"
|
||||
GIT_THEME_PROMPT_PREFIX=" ${green}|"
|
||||
GIT_THEME_PROMPT_SUFFIX="${green}|"
|
||||
GIT_THEME_PROMPT_PREFIX=" ${_omb_prompt_green}|"
|
||||
GIT_THEME_PROMPT_SUFFIX="${_omb_prompt_green}|"
|
||||
|
||||
RVM_THEME_PROMPT_PREFIX="|"
|
||||
RVM_THEME_PROMPT_SUFFIX="|"
|
||||
|
||||
function get_hour_color {
|
||||
hour_color=$red
|
||||
hour_color=$_omb_prompt_red
|
||||
min=$(date +%M)
|
||||
if [ "$min" -lt "15" ]; then
|
||||
hour_color=$_omb_prompt_white
|
||||
elif [ "$min" -lt "30" ]; then
|
||||
hour_color=$green
|
||||
hour_color=$_omb_prompt_green
|
||||
elif [ "$min" -lt "45" ]; then
|
||||
hour_color=$yellow
|
||||
hour_color=$_omb_prompt_yellow
|
||||
else
|
||||
hour_color=$red
|
||||
hour_color=$_omb_prompt_red
|
||||
fi
|
||||
echo "$hour_color"
|
||||
}
|
||||
@@ -34,7 +34,7 @@ __emperor_clock() {
|
||||
}
|
||||
|
||||
function _omb_theme_PROMPT_COMMAND() {
|
||||
PS1="\n$(__emperor_clock)${purple}\h ${_omb_prompt_reset_color}in ${prompt_color}\w\n${_omb_prompt_bold_cyan}$(scm_char)${green}$(scm_prompt_info) ${green}→${_omb_prompt_reset_color} "
|
||||
PS1="\n$(__emperor_clock)${_omb_prompt_magenta}\h ${_omb_prompt_reset_color}in ${prompt_color}\w\n${_omb_prompt_bold_cyan}$(scm_char)${_omb_prompt_green}$(scm_prompt_info) ${_omb_prompt_green}→${_omb_prompt_reset_color} "
|
||||
}
|
||||
|
||||
THEME_CLOCK_FORMAT=${THEME_CLOCK_FORMAT:-"%H "}
|
||||
|
||||
@@ -1,16 +1,16 @@
|
||||
#! bash oh-my-bash.module
|
||||
SCM_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
SCM_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${_omb_prompt_bold_green}✓"
|
||||
SCM_THEME_PROMPT_PREFIX=" |"
|
||||
SCM_THEME_PROMPT_SUFFIX="${green}|"
|
||||
SCM_THEME_PROMPT_SUFFIX="${_omb_prompt_green}|"
|
||||
|
||||
GIT_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
GIT_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
GIT_THEME_PROMPT_CLEAN=" ${_omb_prompt_bold_green}✓"
|
||||
GIT_THEME_PROMPT_PREFIX=" ${green}|"
|
||||
GIT_THEME_PROMPT_SUFFIX="${green}|"
|
||||
GIT_THEME_PROMPT_PREFIX=" ${_omb_prompt_green}|"
|
||||
GIT_THEME_PROMPT_SUFFIX="${_omb_prompt_green}|"
|
||||
|
||||
function _omb_theme_PROMPT_COMMAND() {
|
||||
PS1="\n${yellow}$(_omb_prompt_print_ruby_env) ${purple}\h ${_omb_prompt_reset_color}in ${green}\w\n${_omb_prompt_bold_cyan}$(scm_char)${green}$(scm_prompt_info) ${green}→${_omb_prompt_reset_color} "
|
||||
PS1="\n${_omb_prompt_yellow}$(_omb_prompt_print_ruby_env) ${_omb_prompt_magenta}\h ${_omb_prompt_reset_color}in ${_omb_prompt_green}\w\n${_omb_prompt_bold_cyan}$(scm_char)${_omb_prompt_green}$(scm_prompt_info) ${_omb_prompt_green}→${_omb_prompt_reset_color} "
|
||||
}
|
||||
|
||||
_omb_util_add_prompt_command _omb_theme_PROMPT_COMMAND
|
||||
|
||||
@@ -22,10 +22,10 @@
|
||||
#
|
||||
|
||||
SCM_NONE_CHAR=''
|
||||
SCM_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
SCM_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
SCM_THEME_PROMPT_CLEAN=""
|
||||
SCM_THEME_PROMPT_PREFIX="${green}|"
|
||||
SCM_THEME_PROMPT_SUFFIX="${green}|"
|
||||
SCM_THEME_PROMPT_PREFIX="${_omb_prompt_green}|"
|
||||
SCM_THEME_PROMPT_SUFFIX="${_omb_prompt_green}|"
|
||||
SCM_GIT_SHOW_MINIMAL_INFO=true
|
||||
|
||||
CLOCK_THEME_PROMPT_PREFIX=''
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
#! bash oh-my-bash.module
|
||||
# scm theming
|
||||
SCM_THEME_PROMPT_PREFIX="${yellow}("
|
||||
SCM_THEME_PROMPT_PREFIX="${_omb_prompt_yellow}("
|
||||
SCM_THEME_PROMPT_SUFFIX=")${_omb_prompt_normal}"
|
||||
|
||||
SCM_THEME_PROMPT_DIRTY="*"
|
||||
@@ -25,7 +25,7 @@ scm_prompt() {
|
||||
}
|
||||
|
||||
_omb_theme_PROMPT_COMMAND() {
|
||||
ps_host="${green}\h${_omb_prompt_normal}";
|
||||
ps_host="${_omb_prompt_green}\h${_omb_prompt_normal}";
|
||||
ps_user_mark="${_omb_prompt_bold}\$${_omb_prompt_normal}";
|
||||
ps_root_mark="${_omb_prompt_normal}§"
|
||||
ps_path="${_omb_prompt_normal}\w";
|
||||
|
||||
@@ -22,10 +22,10 @@
|
||||
#
|
||||
|
||||
export SCM_NONE_CHAR=''
|
||||
export SCM_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
export SCM_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
export SCM_THEME_PROMPT_CLEAN=""
|
||||
export SCM_THEME_PROMPT_PREFIX="${green}|"
|
||||
export SCM_THEME_PROMPT_SUFFIX="${green}|"
|
||||
export SCM_THEME_PROMPT_PREFIX="${_omb_prompt_green}|"
|
||||
export SCM_THEME_PROMPT_SUFFIX="${_omb_prompt_green}|"
|
||||
export SCM_GIT_SHOW_MINIMAL_INFO=true
|
||||
|
||||
export VIRTUALENV_THEME_PROMPT_PREFIX='('
|
||||
|
||||
@@ -7,13 +7,13 @@ OSH_THEME_GIT_PROMPT_CLEAN="✓"
|
||||
_omb_theme_half_way_prompt_scm() {
|
||||
local CHAR=$(scm_char)
|
||||
if [[ $CHAR != "$SCM_NONE_CHAR" ]]; then
|
||||
printf '%s' " on ${blue}$(git_current_branch)$(parse_git_dirty)${_omb_prompt_normal} "
|
||||
printf '%s' " on ${_omb_prompt_blue}$(git_current_branch)$(parse_git_dirty)${_omb_prompt_normal} "
|
||||
fi
|
||||
}
|
||||
|
||||
_omb_theme_PROMPT_COMMAND() {
|
||||
local ps_username="${purple}\u${_omb_prompt_normal}"
|
||||
local ps_path="${green}\w${_omb_prompt_normal}"
|
||||
local ps_username="${_omb_prompt_magenta}\u${_omb_prompt_normal}"
|
||||
local ps_path="${_omb_prompt_green}\w${_omb_prompt_normal}"
|
||||
local ps_user_mark="${_omb_prompt_orange}λ${_omb_prompt_normal}"
|
||||
|
||||
PS1="$ps_username in $ps_path$(_omb_theme_half_way_prompt_scm) $ps_user_mark "
|
||||
|
||||
@@ -44,16 +44,16 @@ ORANGE='\[\e[0;33m\]'
|
||||
|
||||
DEFAULT_COLOR="${_omb_prompt_white}"
|
||||
|
||||
USER_COLOR="${purple}"
|
||||
SUPERUSER_COLOR="${red}"
|
||||
USER_COLOR="${_omb_prompt_magenta}"
|
||||
SUPERUSER_COLOR="${_omb_prompt_red}"
|
||||
MACHINE_COLOR=$ORANGE
|
||||
IP_COLOR=$ORANGE
|
||||
DIRECTORY_COLOR="${green}"
|
||||
DIRECTORY_COLOR="${_omb_prompt_green}"
|
||||
|
||||
VE_COLOR="${_omb_prompt_cyan}"
|
||||
RVM_COLOR="${_omb_prompt_cyan}"
|
||||
|
||||
REF_COLOR="${purple}"
|
||||
REF_COLOR="${_omb_prompt_magenta}"
|
||||
|
||||
# SCM prompts
|
||||
SCM_THEME_PROMPT_DIRTY=" ${_omb_prompt_bold_red}✗${_omb_prompt_normal}"
|
||||
|
||||
@@ -3,12 +3,12 @@ SCM_GIT_CHAR="± "
|
||||
SCM_HG_CHAR="☿ "
|
||||
SCM_SVN_CHAR="⑆ "
|
||||
SCM_NONE_CHAR=""
|
||||
SCM_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
SCM_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${_omb_prompt_bold_green}✓"
|
||||
SCM_THEME_PROMPT_PREFIX="|"
|
||||
SCM_THEME_PROMPT_SUFFIX="${green}| "
|
||||
SCM_GIT_AHEAD_CHAR="${green}+"
|
||||
SCM_GIT_BEHIND_CHAR="${red}-"
|
||||
SCM_THEME_PROMPT_SUFFIX="${_omb_prompt_green}| "
|
||||
SCM_GIT_AHEAD_CHAR="${_omb_prompt_green}+"
|
||||
SCM_GIT_BEHIND_CHAR="${_omb_prompt_red}-"
|
||||
|
||||
GIT_THEME_PROMPT_DIRTY=" ${_omb_prompt_bold_red}✗"
|
||||
GIT_THEME_PROMPT_CLEAN=" ${_omb_prompt_bold_green}✓"
|
||||
@@ -34,7 +34,7 @@ function git_prompt_info {
|
||||
|
||||
LAST_PROMPT=""
|
||||
function _omb_theme_PROMPT_COMMAND() {
|
||||
local new_PS1="${_omb_prompt_bold_cyan}$(scm_char)${yellow}$(_omb_prompt_print_ruby_env)${green}\w $(scm_prompt_info)"
|
||||
local new_PS1="${_omb_prompt_bold_cyan}$(scm_char)${_omb_prompt_yellow}$(_omb_prompt_print_ruby_env)${_omb_prompt_green}\w $(scm_prompt_info)"
|
||||
local new_prompt=$(PS1="$new_PS1" "$BASH" --norc -i </dev/null 2>&1 | sed -n '${s/^\(.*\)exit$/\1/p;}')
|
||||
|
||||
if [ "$LAST_PROMPT" = "$new_prompt" ]; then
|
||||
@@ -45,7 +45,7 @@ function _omb_theme_PROMPT_COMMAND() {
|
||||
|
||||
local wrap_char=""
|
||||
[[ ${#new_PS1} -gt $(($COLUMNS/1)) ]] && wrap_char="\n"
|
||||
PS1="${new_PS1}${green}${wrap_char}→${_omb_prompt_reset_color} "
|
||||
PS1="${new_PS1}${_omb_prompt_green}${wrap_char}→${_omb_prompt_reset_color} "
|
||||
}
|
||||
|
||||
_omb_util_add_prompt_command _omb_theme_PROMPT_COMMAND
|
||||
|
||||
@@ -21,20 +21,20 @@ function _omb_theme_PROMPT_COMMAND() {
|
||||
|
||||
local SC
|
||||
if ((status == 0)); then
|
||||
SC="$_omb_prompt_cyan-$_omb_prompt_bold_green(${green}^_^$_omb_prompt_bold_green)";
|
||||
SC="$_omb_prompt_cyan-$_omb_prompt_bold_green(${_omb_prompt_green}^_^$_omb_prompt_bold_green)";
|
||||
else
|
||||
SC="$_omb_prompt_cyan-$_omb_prompt_bold_green(${red}T_T$_omb_prompt_bold_green)";
|
||||
SC="$_omb_prompt_cyan-$_omb_prompt_bold_green(${_omb_prompt_red}T_T$_omb_prompt_bold_green)";
|
||||
fi
|
||||
|
||||
local BC=$(battery_percentage)
|
||||
[[ $BC == no && $BC == -1 ]] && BC=
|
||||
BC=${BC:+${_omb_prompt_cyan}-${green}($BC%)}
|
||||
BC=${BC:+${_omb_prompt_cyan}-${_omb_prompt_green}($BC%)}
|
||||
|
||||
PS1=$TITLEBAR"\n${_omb_prompt_cyan}┌─${_omb_prompt_bold_white}[\u@\h]${_omb_prompt_cyan}─${_omb_prompt_bold_yellow}(\w)$(scm_prompt_info)\n${_omb_prompt_cyan}└─${_omb_prompt_bold_green}[\A]$SC$BC${_omb_prompt_cyan}-${_omb_prompt_bold_cyan}[${green}${_omb_prompt_bold_green}\$${_omb_prompt_bold_cyan}]${green} "
|
||||
PS1=$TITLEBAR"\n${_omb_prompt_cyan}┌─${_omb_prompt_bold_white}[\u@\h]${_omb_prompt_cyan}─${_omb_prompt_bold_yellow}(\w)$(scm_prompt_info)\n${_omb_prompt_cyan}└─${_omb_prompt_bold_green}[\A]$SC$BC${_omb_prompt_cyan}-${_omb_prompt_bold_cyan}[${_omb_prompt_green}${_omb_prompt_bold_green}\$${_omb_prompt_bold_cyan}]${_omb_prompt_green} "
|
||||
}
|
||||
|
||||
# scm theming
|
||||
SCM_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
SCM_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${_omb_prompt_bold_green}✓"
|
||||
SCM_THEME_PROMPT_PREFIX="${_omb_prompt_bold_cyan}("
|
||||
SCM_THEME_PROMPT_SUFFIX="${_omb_prompt_bold_cyan})${_omb_prompt_reset_color}"
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
#! bash oh-my-bash.module
|
||||
|
||||
SCM_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
SCM_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${_omb_prompt_bold_green}✓"
|
||||
SCM_THEME_PROMPT_PREFIX="(${yellow}"
|
||||
SCM_THEME_PROMPT_PREFIX="(${_omb_prompt_yellow}"
|
||||
SCM_THEME_PROMPT_SUFFIX="${_omb_prompt_normal})"
|
||||
|
||||
GIT_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
GIT_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
GIT_THEME_PROMPT_CLEAN=" ${_omb_prompt_bold_green}✓"
|
||||
GIT_THEME_PROMPT_PREFIX="(${yellow}"
|
||||
GIT_THEME_PROMPT_PREFIX="(${_omb_prompt_yellow}"
|
||||
GIT_THEME_PROMPT_SUFFIX="${_omb_prompt_normal})"
|
||||
|
||||
RVM_THEME_PROMPT_PREFIX=""
|
||||
@@ -15,7 +15,7 @@ RVM_THEME_PROMPT_SUFFIX=""
|
||||
|
||||
function _omb_theme_PROMPT_COMMAND() {
|
||||
dtime="$(clock_prompt)"
|
||||
user_host="${green}\u@${_omb_prompt_cyan}\h${_omb_prompt_normal}"
|
||||
user_host="${_omb_prompt_green}\u@${_omb_prompt_cyan}\h${_omb_prompt_normal}"
|
||||
current_dir="${_omb_prompt_bold_blue}\w${_omb_prompt_normal}"
|
||||
rvm_ruby="${_omb_prompt_bold_red}$(_omb_prompt_print_ruby_env)${_omb_prompt_normal}"
|
||||
git_branch="$(scm_prompt_info)${_omb_prompt_normal}"
|
||||
@@ -27,7 +27,7 @@ function _omb_theme_PROMPT_COMMAND() {
|
||||
$arrow $prompt"
|
||||
}
|
||||
|
||||
THEME_CLOCK_COLOR=${THEME_CLOCK_COLOR:-"$yellow"}
|
||||
THEME_CLOCK_COLOR=${THEME_CLOCK_COLOR:-"$_omb_prompt_yellow"}
|
||||
THEME_CLOCK_FORMAT=${THEME_TIME_FORMAT:-"%I:%M:%S "}
|
||||
|
||||
_omb_util_add_prompt_command _omb_theme_PROMPT_COMMAND
|
||||
|
||||
@@ -115,10 +115,10 @@ _omb_theme_PROMPT_COMMAND() {
|
||||
|
||||
# nice prompt
|
||||
case "`id -u`" in
|
||||
0) PS1="\n${TITLEBAR}${BRACKET_COLOR}┌─${_omb_prompt_normal}$(my_ve)$(chroot)[$my_ps_root][$my_ps_host_root]$(modern_scm_prompt)$(__my_rvm_ruby_version)[${green}\w${_omb_prompt_normal}]$(is_vim_shell)${BRACKET_COLOR}
|
||||
0) PS1="\n${TITLEBAR}${BRACKET_COLOR}┌─${_omb_prompt_normal}$(my_ve)$(chroot)[$my_ps_root][$my_ps_host_root]$(modern_scm_prompt)$(__my_rvm_ruby_version)[${_omb_prompt_green}\w${_omb_prompt_normal}]$(is_vim_shell)${BRACKET_COLOR}
|
||||
└─▪ ${prompt_symbol} ${_omb_prompt_normal}"
|
||||
;;
|
||||
*) PS1="\n${TITLEBAR}${BRACKET_COLOR}┌─${_omb_prompt_normal}$(my_ve)$(chroot)[$my_ps_user][$my_ps_host]$(modern_scm_prompt)${_omb_prompt_normal}$(__my_rvm_ruby_version)[${green}\w${_omb_prompt_normal}]$(is_vim_shell)${BRACKET_COLOR}
|
||||
*) PS1="\n${TITLEBAR}${BRACKET_COLOR}┌─${_omb_prompt_normal}$(my_ve)$(chroot)[$my_ps_user][$my_ps_host]$(modern_scm_prompt)${_omb_prompt_normal}$(__my_rvm_ruby_version)[${_omb_prompt_green}\w${_omb_prompt_normal}]$(is_vim_shell)${BRACKET_COLOR}
|
||||
└─▪ ${prompt_symbol} ${_omb_prompt_normal}"
|
||||
;;
|
||||
esac
|
||||
|
||||
@@ -5,12 +5,12 @@
|
||||
# BASED ON: smt by Stephen Tudor (stephen@tudorstudio.com) #
|
||||
# ------------------------------------------------------------------#
|
||||
|
||||
SCM_THEME_PROMPT_DIRTY="${red}⚡${_omb_prompt_reset_color}"
|
||||
SCM_THEME_PROMPT_AHEAD="${red}!${_omb_prompt_reset_color}"
|
||||
SCM_THEME_PROMPT_CLEAN="${green}✓${_omb_prompt_reset_color}"
|
||||
SCM_THEME_PROMPT_DIRTY="${_omb_prompt_red}⚡${_omb_prompt_reset_color}"
|
||||
SCM_THEME_PROMPT_AHEAD="${_omb_prompt_red}!${_omb_prompt_reset_color}"
|
||||
SCM_THEME_PROMPT_CLEAN="${_omb_prompt_green}✓${_omb_prompt_reset_color}"
|
||||
SCM_THEME_PROMPT_PREFIX=" "
|
||||
SCM_THEME_PROMPT_SUFFIX=""
|
||||
GIT_SHA_PREFIX=" ${yellow}"
|
||||
GIT_SHA_PREFIX=" ${_omb_prompt_yellow}"
|
||||
GIT_SHA_SUFFIX="${_omb_prompt_reset_color}"
|
||||
|
||||
function git_short_sha() {
|
||||
@@ -19,8 +19,8 @@ function git_short_sha() {
|
||||
|
||||
function _omb_theme_PROMPT_COMMAND() {
|
||||
local return_status=""
|
||||
local ruby="${red}$(_omb_prompt_print_ruby_env)${_omb_prompt_reset_color}"
|
||||
local user_host="${green}\h${_omb_prompt_reset_color}"
|
||||
local ruby="${_omb_prompt_red}$(_omb_prompt_print_ruby_env)${_omb_prompt_reset_color}"
|
||||
local user_host="${_omb_prompt_green}\h${_omb_prompt_reset_color}"
|
||||
local current_path="\w"
|
||||
local n_commands="\!"
|
||||
local git_branch="$(git_short_sha)$(scm_prompt_info)"
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
#! bash oh-my-bash.module
|
||||
|
||||
SCM_THEME_PROMPT_PREFIX="${_omb_prompt_cyan}(${green}"
|
||||
SCM_THEME_PROMPT_PREFIX="${_omb_prompt_cyan}(${_omb_prompt_green}"
|
||||
SCM_THEME_PROMPT_SUFFIX="${_omb_prompt_cyan})"
|
||||
SCM_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${green}✓"
|
||||
SCM_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${_omb_prompt_green}✓"
|
||||
|
||||
_omb_theme_PROMPT_COMMAND() {
|
||||
PS1="$(scm_prompt_info)${_omb_prompt_reset_color} ${_omb_prompt_cyan}\W${_omb_prompt_reset_color} "
|
||||
|
||||
@@ -20,10 +20,10 @@ function _omb_theme_PROMPT_COMMAND() {
|
||||
}
|
||||
|
||||
# scm theming
|
||||
SCM_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
SCM_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${_omb_prompt_bold_green}✓"
|
||||
SCM_THEME_PROMPT_PREFIX="${green}("
|
||||
SCM_THEME_PROMPT_SUFFIX="${green})${_omb_prompt_reset_color}"
|
||||
SCM_THEME_PROMPT_PREFIX="${_omb_prompt_green}("
|
||||
SCM_THEME_PROMPT_SUFFIX="${_omb_prompt_green})${_omb_prompt_reset_color}"
|
||||
|
||||
|
||||
_omb_util_add_prompt_command _omb_theme_PROMPT_COMMAND
|
||||
|
||||
@@ -16,8 +16,8 @@
|
||||
# since 'fasd' is messing with the $PROMPT_COMMAND
|
||||
|
||||
|
||||
PROMPT_END_CLEAN="${green}→${_omb_prompt_reset_color}"
|
||||
PROMPT_END_DIRTY="${red}→${_omb_prompt_reset_color}"
|
||||
PROMPT_END_CLEAN="${_omb_prompt_green}→${_omb_prompt_reset_color}"
|
||||
PROMPT_END_DIRTY="${_omb_prompt_red}→${_omb_prompt_reset_color}"
|
||||
|
||||
function prompt_end() {
|
||||
echo -e "$PROMPT_END"
|
||||
@@ -32,7 +32,7 @@ _omb_theme_PROMPT_COMMAND() {
|
||||
#history -a
|
||||
#history -c
|
||||
#history -r
|
||||
PS1="($(clock_prompt)) $(scm_char) [${blue}\u${_omb_prompt_reset_color}@${green}\H${_omb_prompt_reset_color}] ${yellow}\w${_omb_prompt_reset_color}$(scm_prompt_info) ${_omb_prompt_reset_color}\n$(prompt_end) "
|
||||
PS1="($(clock_prompt)) $(scm_char) [${_omb_prompt_blue}\u${_omb_prompt_reset_color}@${_omb_prompt_green}\H${_omb_prompt_reset_color}] ${_omb_prompt_yellow}\w${_omb_prompt_reset_color}$(scm_prompt_info) ${_omb_prompt_reset_color}\n$(prompt_end) "
|
||||
PS2='> '
|
||||
PS4='+ '
|
||||
}
|
||||
|
||||
@@ -22,11 +22,11 @@ function randomize_nwinkler {
|
||||
|
||||
AVAILABLE_COLORS=(
|
||||
"$_omb_prompt_black"
|
||||
"$red"
|
||||
"$green"
|
||||
"$yellow"
|
||||
"$blue"
|
||||
"$purple"
|
||||
"$_omb_prompt_red"
|
||||
"$_omb_prompt_green"
|
||||
"$_omb_prompt_yellow"
|
||||
"$_omb_prompt_blue"
|
||||
"$_omb_prompt_magenta"
|
||||
"$_omb_prompt_cyan"
|
||||
"$_omb_prompt_white"
|
||||
"$_omb_prompt_orange"
|
||||
@@ -83,8 +83,8 @@ else
|
||||
echo
|
||||
fi
|
||||
|
||||
PROMPT_END_CLEAN="${green}→${_omb_prompt_reset_color}"
|
||||
PROMPT_END_DIRTY="${red}→${_omb_prompt_reset_color}"
|
||||
PROMPT_END_CLEAN="${_omb_prompt_green}→${_omb_prompt_reset_color}"
|
||||
PROMPT_END_DIRTY="${_omb_prompt_red}→${_omb_prompt_reset_color}"
|
||||
|
||||
function prompt_end() {
|
||||
echo -e "$PROMPT_END"
|
||||
|
||||
@@ -5,7 +5,7 @@ _omb_theme_PROMPT_COMMAND() {
|
||||
history -a
|
||||
history -c
|
||||
history -r
|
||||
PS1="($(clock_prompt)) $(scm_char) [$blue\u$_omb_prompt_reset_color@$green\H$_omb_prompt_reset_color] $yellow\w${_omb_prompt_reset_color}$(scm_prompt_info)$(_omb_prompt_print_ruby_env) $_omb_prompt_reset_color "
|
||||
PS1="($(clock_prompt)) $(scm_char) [$_omb_prompt_blue\u$_omb_prompt_reset_color@$_omb_prompt_green\H$_omb_prompt_reset_color] $_omb_prompt_yellow\w${_omb_prompt_reset_color}$(scm_prompt_info)$(_omb_prompt_print_ruby_env) $_omb_prompt_reset_color "
|
||||
PS2='> '
|
||||
PS4='+ '
|
||||
}
|
||||
|
||||
@@ -2,10 +2,10 @@
|
||||
|
||||
# based of the candy theme, but minimized by odbol
|
||||
function _omb_theme_PROMPT_COMMAND() {
|
||||
PS1="$(clock_prompt) ${_omb_prompt_reset_color}${_omb_prompt_white}\w${_omb_prompt_reset_color}$(scm_prompt_info)${blue} →${_omb_prompt_bold_blue} ${_omb_prompt_reset_color} ";
|
||||
PS1="$(clock_prompt) ${_omb_prompt_reset_color}${_omb_prompt_white}\w${_omb_prompt_reset_color}$(scm_prompt_info)${_omb_prompt_blue} →${_omb_prompt_bold_blue} ${_omb_prompt_reset_color} ";
|
||||
}
|
||||
|
||||
THEME_CLOCK_COLOR=${THEME_CLOCK_COLOR:-"$blue"}
|
||||
THEME_CLOCK_COLOR=${THEME_CLOCK_COLOR:-"$_omb_prompt_blue"}
|
||||
THEME_CLOCK_FORMAT=${THEME_CLOCK_FORMAT:-"%I:%M:%S"}
|
||||
|
||||
_omb_util_add_prompt_command _omb_theme_PROMPT_COMMAND
|
||||
|
||||
@@ -1,14 +1,14 @@
|
||||
#! bash oh-my-bash.module
|
||||
|
||||
SCM_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${green}✓"
|
||||
SCM_THEME_PROMPT_PREFIX=" ${blue}scm:( "
|
||||
SCM_THEME_PROMPT_SUFFIX="${blue} )"
|
||||
SCM_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${_omb_prompt_green}✓"
|
||||
SCM_THEME_PROMPT_PREFIX=" ${_omb_prompt_blue}scm:( "
|
||||
SCM_THEME_PROMPT_SUFFIX="${_omb_prompt_blue} )"
|
||||
|
||||
GIT_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
GIT_THEME_PROMPT_CLEAN=" ${green}✓"
|
||||
GIT_THEME_PROMPT_PREFIX="${green}git:( "
|
||||
GIT_THEME_PROMPT_SUFFIX="${green} )"
|
||||
GIT_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
GIT_THEME_PROMPT_CLEAN=" ${_omb_prompt_green}✓"
|
||||
GIT_THEME_PROMPT_PREFIX="${_omb_prompt_green}git:( "
|
||||
GIT_THEME_PROMPT_SUFFIX="${_omb_prompt_green} )"
|
||||
|
||||
function git_prompt_info {
|
||||
git_prompt_vars
|
||||
|
||||
@@ -4,8 +4,8 @@ SCM_THEME_PROMPT_PREFIX="|"
|
||||
SCM_THEME_PROMPT_SUFFIX=""
|
||||
|
||||
SCM_THEME_PROMPT_DIRTY=" ${_omb_prompt_bold_red}✗${_omb_prompt_normal}"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${green}✓${_omb_prompt_normal}"
|
||||
SCM_GIT_CHAR="${green}±${_omb_prompt_normal}"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${_omb_prompt_green}✓${_omb_prompt_normal}"
|
||||
SCM_GIT_CHAR="${_omb_prompt_green}±${_omb_prompt_normal}"
|
||||
SCM_SVN_CHAR="${_omb_prompt_bold_cyan}⑆${_omb_prompt_normal}"
|
||||
SCM_HG_CHAR="${_omb_prompt_bold_red}☿${_omb_prompt_normal}"
|
||||
|
||||
@@ -26,11 +26,11 @@ scm_prompt() {
|
||||
|
||||
_omb_theme_PROMPT_COMMAND() {
|
||||
ps_host="${_omb_prompt_bold_blue}\h${_omb_prompt_normal}";
|
||||
ps_user="${green}\u${_omb_prompt_normal}";
|
||||
ps_user_mark="${green} $ ${_omb_prompt_normal}";
|
||||
ps_root="${red}\u${red}";
|
||||
ps_root_mark="${red} # ${_omb_prompt_normal}"
|
||||
ps_path="${yellow}\w${_omb_prompt_normal}";
|
||||
ps_user="${_omb_prompt_green}\u${_omb_prompt_normal}";
|
||||
ps_user_mark="${_omb_prompt_green} $ ${_omb_prompt_normal}";
|
||||
ps_root="${_omb_prompt_red}\u${_omb_prompt_red}";
|
||||
ps_root_mark="${_omb_prompt_red} # ${_omb_prompt_normal}"
|
||||
ps_path="${_omb_prompt_yellow}\w${_omb_prompt_normal}";
|
||||
|
||||
# make it work
|
||||
case $(id -u) in
|
||||
|
||||
@@ -15,7 +15,7 @@ STATUS_THEME_PROMPT_OK="${_omb_prompt_bold_green}❯${_omb_prompt_reset_color}${
|
||||
|
||||
function _omb_theme_PROMPT_COMMAND() {
|
||||
local ret_status="$( [ $? -eq 0 ] && echo -e "$STATUS_THEME_PROMPT_OK" || echo -e "$STATUS_THEME_PROMPT_BAD")"
|
||||
PS1="\n${blue}\w $(scm_prompt_info)\n${ret_status} "
|
||||
PS1="\n${_omb_prompt_blue}\w $(scm_prompt_info)\n${ret_status} "
|
||||
}
|
||||
|
||||
_omb_util_add_prompt_command _omb_theme_PROMPT_COMMAND
|
||||
|
||||
@@ -11,9 +11,9 @@ _omb_theme_PROMPT_COMMAND() {
|
||||
history -c
|
||||
history -r
|
||||
# displays user@server in purple
|
||||
# PS1="$red$(scm_char) $purple\u@\h$_omb_prompt_reset_color:$blue\w$yellow$(scm_prompt_info)$(_omb_prompt_print_ruby_env) $_omb_prompt_black\$$_omb_prompt_reset_color "
|
||||
# PS1="$_omb_prompt_red$(scm_char) $_omb_prompt_magenta\u@\h$_omb_prompt_reset_color:$_omb_prompt_blue\w$_omb_prompt_yellow$(scm_prompt_info)$(_omb_prompt_print_ruby_env) $_omb_prompt_black\$$_omb_prompt_reset_color "
|
||||
# no user@server
|
||||
PS1="$red$(scm_char) $blue\w$yellow$(scm_prompt_info)$(_omb_prompt_print_ruby_env) $_omb_prompt_black\$$_omb_prompt_reset_color "
|
||||
PS1="$_omb_prompt_red$(scm_char) $_omb_prompt_blue\w$_omb_prompt_yellow$(scm_prompt_info)$(_omb_prompt_print_ruby_env) $_omb_prompt_black\$$_omb_prompt_reset_color "
|
||||
PS2='> '
|
||||
PS4='+ '
|
||||
}
|
||||
@@ -21,9 +21,9 @@ _omb_theme_PROMPT_COMMAND() {
|
||||
_omb_util_add_prompt_command _omb_theme_PROMPT_COMMAND
|
||||
|
||||
SCM_NONE_CHAR='·'
|
||||
SCM_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${green}✓"
|
||||
SCM_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${_omb_prompt_green}✓"
|
||||
SCM_THEME_PROMPT_PREFIX=" ("
|
||||
SCM_THEME_PROMPT_SUFFIX="${yellow})"
|
||||
SCM_THEME_PROMPT_SUFFIX="${_omb_prompt_yellow})"
|
||||
RVM_THEME_PROMPT_PREFIX=" ("
|
||||
RVM_THEME_PROMPT_SUFFIX=")"
|
||||
|
||||
@@ -3,8 +3,8 @@
|
||||
|
||||
# set colors for use throughout the prompt
|
||||
# i like things consistent
|
||||
OMB_THEME_BRACKET_COLOR="${OMB_THEME_BRACKET_COLOR-${blue}}"
|
||||
OMB_THEME_STRING_COLOR="${OMB_THEME_STRING_COLOR-${green}}"
|
||||
OMB_THEME_BRACKET_COLOR="${OMB_THEME_BRACKET_COLOR-${_omb_prompt_blue}}"
|
||||
OMB_THEME_STRING_COLOR="${OMB_THEME_STRING_COLOR-${_omb_prompt_green}}"
|
||||
|
||||
SCM_THEME_PROMPT_PREFIX=""
|
||||
SCM_THEME_PROMPT_SUFFIX=""
|
||||
|
||||
@@ -8,9 +8,9 @@ export PROMPT_DIRTRIM=3
|
||||
|
||||
function _omb_theme_PROMPT_COMMAND() {
|
||||
if [[ ${EUID} == 0 ]] ; then
|
||||
PS1="[$(clock_prompt)]${yellow}[${red}\u@\h ${green}\w${yellow}]${red}$(__git_ps1 "(%s)")${_omb_prompt_normal}\\$ "
|
||||
PS1="[$(clock_prompt)]${_omb_prompt_yellow}[${_omb_prompt_red}\u@\h ${_omb_prompt_green}\w${_omb_prompt_yellow}]${_omb_prompt_red}$(__git_ps1 "(%s)")${_omb_prompt_normal}\\$ "
|
||||
else
|
||||
PS1="[$(clock_prompt)]${yellow}[${_omb_prompt_cyan}\u@\h ${green}\w${yellow}]${red}$(__git_ps1 "(%s)")${_omb_prompt_normal}\\$ "
|
||||
PS1="[$(clock_prompt)]${_omb_prompt_yellow}[${_omb_prompt_cyan}\u@\h ${_omb_prompt_green}\w${_omb_prompt_yellow}]${_omb_prompt_red}$(__git_ps1 "(%s)")${_omb_prompt_normal}\\$ "
|
||||
fi
|
||||
}
|
||||
|
||||
|
||||
@@ -13,7 +13,7 @@ case $TERM in
|
||||
esac
|
||||
|
||||
function _omb_theme_PROMPT_COMMAND() {
|
||||
PS1="${TITLEBAR}${_omb_prompt_orange}${_omb_prompt_reset_color}${green}\w${_omb_prompt_bold_blue}\[\$(scm_prompt_info)\]${_omb_prompt_normal} "
|
||||
PS1="${TITLEBAR}${_omb_prompt_orange}${_omb_prompt_reset_color}${_omb_prompt_green}\w${_omb_prompt_bold_blue}\[\$(scm_prompt_info)\]${_omb_prompt_normal} "
|
||||
}
|
||||
|
||||
# scm themeing
|
||||
|
||||
@@ -15,7 +15,7 @@ function _omb_theme_sirup_rubygem {
|
||||
|
||||
function _omb_theme_PROMPT_COMMAND {
|
||||
# Check http://github.com/Sirupsen/dotfiles for screenshot
|
||||
PS1="$blue\W/$_omb_prompt_bold_blue$(_omb_theme_sirup_rubygem)$_omb_prompt_bold_green$(__git_ps1 " (%s)") ${_omb_prompt_normal}$ "
|
||||
PS1="$_omb_prompt_blue\W/$_omb_prompt_bold_blue$(_omb_theme_sirup_rubygem)$_omb_prompt_bold_green$(__git_ps1 " (%s)") ${_omb_prompt_normal}$ "
|
||||
}
|
||||
|
||||
_omb_util_add_prompt_command _omb_theme_PROMPT_COMMAND
|
||||
|
||||
@@ -33,7 +33,7 @@ __my_rvm_ruby_version() {
|
||||
__my_venv_prompt() {
|
||||
if [ ! -z "$VIRTUAL_ENV" ]
|
||||
then
|
||||
echo "[${blue}@${_omb_prompt_normal}${VIRTUAL_ENV##*/}]"
|
||||
echo "[${_omb_prompt_blue}@${_omb_prompt_normal}${VIRTUAL_ENV##*/}]"
|
||||
fi
|
||||
}
|
||||
|
||||
@@ -57,11 +57,11 @@ modern_scm_prompt() {
|
||||
_omb_theme_PROMPT_COMMAND() {
|
||||
|
||||
case $HOSTNAME in
|
||||
"clappy"* ) my_ps_host="${green}\h${_omb_prompt_normal}";
|
||||
"clappy"* ) my_ps_host="${_omb_prompt_green}\h${_omb_prompt_normal}";
|
||||
;;
|
||||
"icekernel") my_ps_host="${red}\h${_omb_prompt_normal}";
|
||||
"icekernel") my_ps_host="${_omb_prompt_red}\h${_omb_prompt_normal}";
|
||||
;;
|
||||
* ) my_ps_host="${green}\h${_omb_prompt_normal}";
|
||||
* ) my_ps_host="${_omb_prompt_green}\h${_omb_prompt_normal}";
|
||||
;;
|
||||
esac
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@ case $TERM in
|
||||
esac
|
||||
|
||||
function _omb_theme_PROMPT_COMMAND() {
|
||||
PROMPT='${green}\u${_omb_prompt_normal}@${green}\h${_omb_prompt_normal}:${blue}\w${_omb_prompt_normal}${red}$(prompt_char)$(git_prompt_info)${_omb_prompt_normal}\$ '
|
||||
PROMPT='${_omb_prompt_green}\u${_omb_prompt_normal}@${_omb_prompt_green}\h${_omb_prompt_normal}:${_omb_prompt_blue}\w${_omb_prompt_normal}${_omb_prompt_red}$(prompt_char)$(git_prompt_info)${_omb_prompt_normal}\$ '
|
||||
}
|
||||
|
||||
_omb_util_add_prompt_command _omb_theme_PROMPT_COMMAND
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
#! bash oh-my-bash.module
|
||||
|
||||
SCM_THEME_PROMPT_PREFIX=" ${purple}"
|
||||
SCM_THEME_PROMPT_PREFIX=" ${_omb_prompt_magenta}"
|
||||
SCM_THEME_PROMPT_SUFFIX=" ${_omb_prompt_normal}"
|
||||
SCM_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${green}✓"
|
||||
SCM_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${_omb_prompt_green}✓"
|
||||
SCM_GIT_SHOW_DETAILS="false"
|
||||
|
||||
function _omb_theme_PROMPT_COMMAND() {
|
||||
PS1="${yellow}\u${_omb_prompt_normal}${_omb_prompt_cyan}@\h${_omb_prompt_normal}${purple} ${_omb_prompt_normal}${green}\w${_omb_prompt_normal}$(scm_prompt_info)> "
|
||||
PS1="${_omb_prompt_yellow}\u${_omb_prompt_normal}${_omb_prompt_cyan}@\h${_omb_prompt_normal}${_omb_prompt_magenta} ${_omb_prompt_normal}${_omb_prompt_green}\w${_omb_prompt_normal}$(scm_prompt_info)> "
|
||||
}
|
||||
|
||||
_omb_util_add_prompt_command _omb_theme_PROMPT_COMMAND
|
||||
|
||||
@@ -3,10 +3,10 @@
|
||||
# Based on 'bobby' theme with the addition of python_venv
|
||||
#
|
||||
|
||||
SCM_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${green}✓"
|
||||
SCM_THEME_PROMPT_PREFIX=" ${yellow}|${_omb_prompt_reset_color}"
|
||||
SCM_THEME_PROMPT_SUFFIX="${yellow}|"
|
||||
SCM_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${_omb_prompt_green}✓"
|
||||
SCM_THEME_PROMPT_PREFIX=" ${_omb_prompt_yellow}|${_omb_prompt_reset_color}"
|
||||
SCM_THEME_PROMPT_SUFFIX="${_omb_prompt_yellow}|"
|
||||
|
||||
RVM_THEME_PROMPT_PREFIX="|"
|
||||
RVM_THEME_PROMPT_SUFFIX="|"
|
||||
@@ -14,7 +14,7 @@ VIRTUALENV_THEME_PROMPT_PREFIX='|'
|
||||
VIRTUALENV_THEME_PROMPT_SUFFIX='|'
|
||||
|
||||
function _omb_theme_PROMPT_COMMAND() {
|
||||
PS1="\n${green}$(_omb_prompt_print_python_venv)${red}$(_omb_prompt_print_ruby_env) ${_omb_prompt_reset_color}\h ${_omb_prompt_orange}in ${_omb_prompt_reset_color}\w\n${yellow}$(scm_char)$(scm_prompt_info) ${yellow}→${_omb_prompt_white} "
|
||||
PS1="\n${_omb_prompt_green}$(_omb_prompt_print_python_venv)${_omb_prompt_red}$(_omb_prompt_print_ruby_env) ${_omb_prompt_reset_color}\h ${_omb_prompt_orange}in ${_omb_prompt_reset_color}\w\n${_omb_prompt_yellow}$(scm_char)$(scm_prompt_info) ${_omb_prompt_yellow}→${_omb_prompt_white} "
|
||||
}
|
||||
|
||||
_omb_util_add_prompt_command _omb_theme_PROMPT_COMMAND
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
#! bash oh-my-bash.module
|
||||
SCM_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
SCM_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
SCM_THEME_PROMPT_CLEAN=" ${_omb_prompt_bold_green}✓"
|
||||
SCM_THEME_PROMPT_PREFIX=" |"
|
||||
SCM_THEME_PROMPT_SUFFIX="${green}|"
|
||||
SCM_THEME_PROMPT_SUFFIX="${_omb_prompt_green}|"
|
||||
|
||||
GIT_THEME_PROMPT_DIRTY=" ${red}✗"
|
||||
GIT_THEME_PROMPT_DIRTY=" ${_omb_prompt_red}✗"
|
||||
GIT_THEME_PROMPT_CLEAN=" ${_omb_prompt_bold_green}✓"
|
||||
GIT_THEME_PROMPT_PREFIX=" ${green}|"
|
||||
GIT_THEME_PROMPT_SUFFIX="${green}|"
|
||||
GIT_THEME_PROMPT_PREFIX=" ${_omb_prompt_green}|"
|
||||
GIT_THEME_PROMPT_SUFFIX="${_omb_prompt_green}|"
|
||||
|
||||
RVM_THEME_PROMPT_PREFIX="|"
|
||||
RVM_THEME_PROMPT_SUFFIX="|"
|
||||
@@ -18,9 +18,9 @@ function _omb_theme_PROMPT_COMMAND() {
|
||||
else
|
||||
status=💔
|
||||
fi
|
||||
PS1="\n${yellow}$(_omb_prompt_print_ruby_env) ${purple}\h ${_omb_prompt_reset_color}in ${green}\w $status \n${_omb_prompt_bold_cyan} ${blue}|$(clock_prompt)|${green}$(scm_prompt_info) ${green}→${_omb_prompt_reset_color} "
|
||||
PS1="\n${_omb_prompt_yellow}$(_omb_prompt_print_ruby_env) ${_omb_prompt_magenta}\h ${_omb_prompt_reset_color}in ${_omb_prompt_green}\w $status \n${_omb_prompt_bold_cyan} ${_omb_prompt_blue}|$(clock_prompt)|${_omb_prompt_green}$(scm_prompt_info) ${_omb_prompt_green}→${_omb_prompt_reset_color} "
|
||||
}
|
||||
|
||||
THEME_CLOCK_COLOR=${THEME_CLOCK_COLOR:-"$blue"}
|
||||
THEME_CLOCK_COLOR=${THEME_CLOCK_COLOR:-"$_omb_prompt_blue"}
|
||||
|
||||
_omb_util_add_prompt_command _omb_theme_PROMPT_COMMAND
|
||||
|
||||
@@ -68,9 +68,9 @@ my_ve(){
|
||||
|
||||
_omb_theme_PROMPT_COMMAND() {
|
||||
|
||||
my_ps_host="${green}\h${_omb_prompt_normal}";
|
||||
my_ps_host="${_omb_prompt_green}\h${_omb_prompt_normal}";
|
||||
# yes, these are the the same for now ...
|
||||
my_ps_host_root="${green}\h${_omb_prompt_normal}";
|
||||
my_ps_host_root="${_omb_prompt_green}\h${_omb_prompt_normal}";
|
||||
|
||||
my_ps_user="${_omb_prompt_bold_green}\u${_omb_prompt_normal}"
|
||||
my_ps_root="${_omb_prompt_bold_red}\u${_omb_prompt_normal}";
|
||||
|
||||
Reference in New Issue
Block a user