Skip to content

Instantly share code, notes, and snippets.

@DamianEdwards
Last active October 6, 2021 19:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save DamianEdwards/e20dd4fd66c53da32a2b2cae65e478a3 to your computer and use it in GitHub Desktop.
Save DamianEdwards/e20dd4fd66c53da32a2b2cae65e478a3 to your computer and use it in GitHub Desktop.
Trying to make an oh-my-posh text segment that hides itself when there's no value
{
"type": "text", // VS version
"style": "powerline",
"powerline_symbol": "\uE0C4",
"foreground": "#ffffff",
"background": "#5C2D91", // VS purple from https://visualstudio.microsoft.com/
"properties": {
"prefix": "",
"text": "{{if .Env.VSCMD_VER}} ﬏ {{.Env.VSCMD_VER}} {{end}}",
"postfix": ""
}
},
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment