oh-my-posh: macos bash not supported [[ -v MC_SID ]]
Code of Conduct
- I agree to follow this project’s Code of Conduct
What happened?
bash: eval: line 25: conditional binary operator expected
bash: eval: line 25: syntax error near MC_SID' bash: eval: line 25: if [[ -v MC_SID ]];then’
Theme
M365Princess
What OS are you seeing the problem on?
macOS
Which shell are you using?
bash
Log output
[DEBUG] 17:41:24.360 shell.go:Getenv:342 → /Users/wishyes/.cache
[TRACE] 17:41:24.360 shell.go:Getenv(XDG_CACHE_HOME) - 2.736458ms
[TRACE] 17:41:24.360 shell_unix.go:CachePath() - 2.766ms
[DEBUG] 17:41:24.360 shell.go:Getenv:342 → /opt/homebrew/Cellar/oh-my-posh/14.0.0/themes/M365Princess.omp.json
[TRACE] 17:41:24.360 shell.go:Getenv(POSH_THEME) - 4.792µs
[TRACE] 17:41:24.360 shell.go:resolveConfigPath() - 9.667µs
[TRACE] 17:41:24.360 shell.go:Init() - 3.585416ms
[TRACE] 17:41:24.360 shell.go:Flags() - 42ns
[TRACE] 17:41:24.362 config.go:loadConfig() - 505.042µs
[TRACE] 17:41:24.362 shell.go:Flags() - 83ns
[DEBUG] 17:41:24.362 shell.go:Getenv:342 → NO DATA
[TRACE] 17:41:24.362 shell.go:Getenv(OMP_CACHE_DISABLED) - 3.458µs
About this issue
- Original URL
- State: closed
- Created a year ago
- Comments: 16 (5 by maintainers)
My bad. Seems VScode update somehow tossed out my shell settings. On closer inspection I realized vscode was launching the OSX native 3.x bash. Added a new shell profile using the brew provided bash again. All good now.
🧑🔧 Quick fix. Where you have something like
replace it by
I wonder who thought midnight commander is more relevant than macOS
OK…sorry for the posts 😟
Despite a
which bashshowing correctly and my initial setup script running achshduring setup, my login shell was still set to/bin/bash😊So, ‘update your bash’ is correct, just make sure you are using that bash 🥳
@JanDeDobbeleer thanks, bash has been updated