|
|
@ -471,7 +471,7 @@ prompt_dir() {
|
|
|
|
# GO prompt
|
|
|
|
# GO prompt
|
|
|
|
prompt_go_version() {
|
|
|
|
prompt_go_version() {
|
|
|
|
local go_version
|
|
|
|
local go_version
|
|
|
|
go_version=$(go version 2>&1 | sed -E "s/.*(go[0-9.]*).*/\1/")
|
|
|
|
go_version=$(go version 2>/dev/null | sed -E "s/.*(go[0-9.]*).*/\1/")
|
|
|
|
|
|
|
|
|
|
|
|
if [[ -n "$go_version" ]]; then
|
|
|
|
if [[ -n "$go_version" ]]; then
|
|
|
|
"$1_prompt_segment" "$0" "$2" "green" "255" "$go_version"
|
|
|
|
"$1_prompt_segment" "$0" "$2" "green" "255" "$go_version"
|
|
|
|