File tree Expand file tree Collapse file tree 5 files changed +18
-9
lines changed Expand file tree Collapse file tree 5 files changed +18
-9
lines changed Original file line number Diff line number Diff line change @@ -21,11 +21,13 @@ function git_short_sha() {
2121
2222function prompt() {
2323 local return_status=" "
24- local ruby=" ${red?} $( ruby_version_prompt) ${reset_color?} "
24+ local ruby
25+ ruby=" ${red?} $( ruby_version_prompt) ${reset_color?} "
2526 local user_host=" ${green?} \h${reset_color?} "
2627 local current_path=" \w"
2728 local n_commands=" \!"
28- local git_branch=" $( git_short_sha) $( scm_prompt_info) "
29+ local git_branch
30+ git_branch=" $( git_short_sha) $( scm_prompt_info) "
2931 local prompt_symbol=' λ'
3032 local open=' ('
3133 local close=' )'
Original file line number Diff line number Diff line change @@ -42,7 +42,8 @@ function __powerline_prompt_command {
4242
4343 # # left prompt ##
4444 for segment in $POWERLINE_PROMPT ; do
45- local info=" $( __powerline_${segment} _prompt) "
45+ local info
46+ info=" $( __powerline_${segment} _prompt) "
4647 [[ -n " ${info} " ]] && __powerline_left_segment " ${info} "
4748 done
4849
Original file line number Diff line number Diff line change 55GIT_PS1_SHOWDIRTYSTATE=" enabled"
66
77function rvm_version_prompt {
8- local gemset=$( echo $GEM_HOME | awk -F' @' ' {print $2}' )
8+ local gemset
9+ gemset=$( echo $GEM_HOME | awk -F' @' ' {print $2}' )
910
1011 [ " $gemset " != " " ] && gemset=" @$gemset "
11- local version=$( echo $MY_RUBY_HOME | awk -F' -' ' {print $2}' )
12+ local version
13+ version=$( echo $MY_RUBY_HOME | awk -F' -' ' {print $2}' )
1214
1315 [ " $version " == " 1.9.2" ] && version=" "
1416
Original file line number Diff line number Diff line change 2525PS3=" >> "
2626
2727__my_rvm_ruby_version () {
28- local gemset=$( echo $GEM_HOME | awk -F' @' ' {print $2}' )
28+ local gemset
29+ gemset=$( echo $GEM_HOME | awk -F' @' ' {print $2}' )
2930 [ " $gemset " != " " ] && gemset=" @$gemset "
30- local version=$( echo $MY_RUBY_HOME | awk -F' -' ' {print $2}' )
31+ local version
32+ version=$( echo $MY_RUBY_HOME | awk -F' -' ' {print $2}' )
3133 local full=" $version$gemset "
3234 [ " $full " != " " ] && echo " [$full ]"
3335}
Original file line number Diff line number Diff line change 2525PS3=" >> "
2626
2727__my_rvm_ruby_version () {
28- local gemset=$( echo $GEM_HOME | awk -F' @' ' {print $2}' )
28+ local gemset
29+ gemset=$( echo $GEM_HOME | awk -F' @' ' {print $2}' )
2930 [ " $gemset " != " " ] && gemset=" @$gemset "
30- local version=$( echo $MY_RUBY_HOME | awk -F' -' ' {print $2}' )
31+ local version
32+ version=$( echo $MY_RUBY_HOME | awk -F' -' ' {print $2}' )
3133 local full=" $version$gemset "
3234 [ " $full " != " " ] && echo " [$full ]"
3335}
You can’t perform that action at this time.
0 commit comments