Skip to content

Commit ac6de26

Browse files
committed
Fix issue #255: use awk to get golang version
1 parent 06f1d86 commit ac6de26

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

bullet-train.zsh-theme

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -536,7 +536,7 @@ prompt_go() {
536536
setopt extended_glob
537537
if [[ (-f *.go(#qN) || -d Godeps || -f glide.yaml) ]]; then
538538
if command -v go > /dev/null 2>&1; then
539-
prompt_segment $BULLETTRAIN_GO_BG $BULLETTRAIN_GO_FG $BULLETTRAIN_GO_PREFIX" $(go version | grep --colour=never -oE '[[:digit:]].[[:digit:]]')"
539+
prompt_segment $BULLETTRAIN_GO_BG $BULLETTRAIN_GO_FG $BULLETTRAIN_GO_PREFIX" $(go version | awk '{print substr($3, 3)}')"
540540
fi
541541
fi
542542
}

0 commit comments

Comments
 (0)