oh-my-fish / theme-bobthefish

A Powerline-style, Git-aware fish theme optimized for awesome.
MIT License
1.46k stars 227 forks source link

Go version display broken #372

Closed air1bzz closed 1 month ago

air1bzz commented 4 months ago

When checking out in a go project directory, I have the following error:

string match: Unknown option “-g”

~/.local/share/omf/themes/bobthefish/functions/fish_prompt.fish (line 1): 
go version | string match -r 'go version go(\\d+\\.\\d+(?:\\.\\d+)?)' -g
^
in command substitution
    called on line 876 of file ~/.local/share/omf/themes/bobthefish/functions/fish_prompt.fish
in function '__bobthefish_prompt_golang' with arguments '/home/air1bzz/code/binary_clock'
    called on line 1314 of file ~/.local/share/omf/themes/bobthefish/functions/fish_prompt.fish
in function 'fish_prompt'
in command substitution

(Type 'help string' for related documentation)

It is because of the call of function __bobthefish_prompt_golang, Display is broken because of the unknown -g flag passed to the string match command.

air1bzz commented 2 months ago

cc @bobthecow

bobthecow commented 2 months ago

Oh sorry, I'm not sure how I missed this before!