mirror of
https://github.com/JanDeDobbeleer/oh-my-posh.git
synced 2025-01-03 07:17:26 -08:00
2 KiB
2 KiB
id | title | sidebar_label |
---|---|---|
debug-prompt | Debug prompt | Debug prompt |
:::info
This feature only works in powershell
for the time being.
:::
The debug prompt is displayed when you debug a script from the command line or Visual Studio Code.
The default is [DBG]:
.
You can use go text/template templates extended with sprig to enrich the text.
Environment variables are available, just like the console_title_template
functionality.
Configuration
You need to extend or create a custom theme with your debug prompt override. For example:
{
"$schema": "https://raw.githubusercontent.com/JanDeDobbeleer/oh-my-posh/main/themes/schema.json",
"blocks": [
...
],
"debug_prompt": {
"background": "transparent",
"foreground": "#ffffff",
"template": "Debugging "
}
}
The configuration has the following properties:
- foreground:
string
color - foreground_templates: foreground color templates
- background:
string
color - background_templates: background color templates
- template:
string
- a go text/template template extended with sprig utilizing the properties below - defaults to[DBG]:
Template (info)
.Root
:boolean
- is the current user root/admin or not.PWD
:string
- the current working directory.Folder
:string
- the current working folder.Shell
:string
- the current shell name.UserName
:string
- the current user name.HostName
:string
- the host name.Env.VarName
:string
- Any environment variable whereVarName
is the environment variable name