mirror of
https://git.sr.ht/~coasteen/dotfiles
synced 2026-02-04 06:03:45 +01:00
35 lines
1 KiB
Text
35 lines
1 KiB
Text
export-env { $env.STARSHIP_SHELL = "nu"; load-env {
|
|
STARSHIP_SESSION_KEY: (random chars -l 16)
|
|
PROMPT_MULTILINE_INDICATOR: (
|
|
^/etc/profiles/per-user/coast/bin/starship prompt --continuation
|
|
)
|
|
|
|
# Does not play well with default character module.
|
|
# TODO: Also Use starship vi mode indicators?
|
|
PROMPT_INDICATOR: ""
|
|
|
|
PROMPT_COMMAND: {||
|
|
# jobs are not supported
|
|
(
|
|
^/etc/profiles/per-user/coast/bin/starship prompt
|
|
--cmd-duration $env.CMD_DURATION_MS
|
|
$"--status=($env.LAST_EXIT_CODE)"
|
|
--terminal-width (term size).columns
|
|
)
|
|
}
|
|
|
|
config: ($env.config? | default {} | merge {
|
|
render_right_prompt_on_last_line: true
|
|
})
|
|
|
|
PROMPT_COMMAND_RIGHT: {||
|
|
(
|
|
^/etc/profiles/per-user/coast/bin/starship prompt
|
|
--right
|
|
--cmd-duration $env.CMD_DURATION_MS
|
|
$"--status=($env.LAST_EXIT_CODE)"
|
|
--terminal-width (term size).columns
|
|
)
|
|
}
|
|
}}
|
|
|