Session
Whatâ
Show the current user and host name.
Sample Configurationâ
- json
- yaml
- toml
{
"type": "session",
"style": "diamond",
"foreground": "#ffffff",
"background": "#c386f1",
"leading_diamond": "îś",
"trailing_diamond": "î°",
"template": "{{ if .SSHSession }} {{ end }}{{ .UserName }}"
}
type: session
style: diamond
foreground: "#ffffff"
background: "#c386f1"
leading_diamond: îś
trailing_diamond: î°
template: "{{ if .SSHSession }} {{ end }}{{ .UserName }}"
type = "session"
style = "diamond"
foreground = "#ffffff"
background = "#c386f1"
leading_diamond = "îś"
trailing_diamond = "î°"
template = "{{ if .SSHSession }} {{ end }}{{ .UserName }}"
Template (info)â
default template
{{ if .SSHSession }}\ueba9 {{ end }}{{ .UserName }}@{{ .HostName }}
Propertiesâ
Name | Type | Description |
---|---|---|
.UserName | string | the current user's name |
.HostName | string | the current computer's name |
.SSHSession | boolean | active SSH session or not |
.Root | boolean | are you a root/admin user or not |