Direct naar hoofdinhoud

Secundaire prompt

Onofficiële Beta-vertaling

Deze pagina is vertaald door PageTurner AI (beta). Niet officieel goedgekeurd door het project. Een fout gevonden? Probleem melden →

informatie

Deze functie werkt momenteel alleen in powershell, zsh en bash.

De secundaire prompt wordt weergegeven wanneer een opdracht meerdere regels beslaat. De standaardinstelling is > .

Je kunt go text/template templates gebruiken, uitgebreid met sprig, om de tekst te verrijken. Omgevingsvariabelen zijn beschikbaar, net als bij de console_title_template functionaliteit.

Configuratie

Je moet een bestaand thema aanpassen of een nieuw thema maken met je eigen secundaire prompt. Bijvoorbeeld:

{
"secondary_prompt": {
"background": "transparent",
"foreground": "#ffffff",
"template": "-> "
}
}

Opties

NameTypeDescription
backgroundstringcolor
foregroundstringcolor
templatestringa go text/template template extended with sprig utilizing the properties below - defaults to >

Template (informatie)

NameTypeDescription
.Rootbooleanis the current user root/admin or not
.Shellstringthe current shell name
.UserNamestringthe current user name
.HostNamestringthe host name