theme/pete: `shellcheck` && `shfmt`
parent
86c1e3c043
commit
8e8fe69db4
|
|
@ -150,6 +150,7 @@ themes/command_duration.theme.bash
|
||||||
themes/easy
|
themes/easy
|
||||||
themes/essential
|
themes/essential
|
||||||
themes/modern
|
themes/modern
|
||||||
|
themes/pete
|
||||||
themes/powerline
|
themes/powerline
|
||||||
themes/pure
|
themes/pure
|
||||||
themes/purity
|
themes/purity
|
||||||
|
|
|
||||||
|
|
@ -1,11 +1,16 @@
|
||||||
# shellcheck shell=bash
|
# shellcheck shell=bash
|
||||||
|
# shellcheck disable=SC2034 # Expected behavior for themes.
|
||||||
|
|
||||||
prompt_setter() {
|
function prompt_setter() {
|
||||||
# Save history
|
local clock_prompt scm_char scm_prompt_info ruby_version_prompt
|
||||||
_save-and-reload-history 1
|
clock_prompt="$(clock_prompt)"
|
||||||
PS1="($(clock_prompt)) $(scm_char) [$blue\u$reset_color@$green\H$reset_color] $yellow\w${reset_color}$(scm_prompt_info)$(ruby_version_prompt) $reset_color "
|
scm_char="$(scm_char)"
|
||||||
PS2='> '
|
scm_prompt_info="$(scm_prompt_info)"
|
||||||
PS4='+ '
|
ruby_version_prompt="$(ruby_version_prompt)"
|
||||||
|
_save-and-reload-history 1 # Save history
|
||||||
|
PS1="(${clock_prompt}) ${scm_char} [${blue?}\u${reset_color?}@${green?}\H${reset_color?}] ${yellow?}\w${reset_color?}${scm_prompt_info}${ruby_version_prompt} ${reset_color?} "
|
||||||
|
PS2='> '
|
||||||
|
PS4='+ '
|
||||||
}
|
}
|
||||||
|
|
||||||
safe_append_prompt_command prompt_setter
|
safe_append_prompt_command prompt_setter
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue