Skip to content

Latest commit

 

History

History
43 lines (27 loc) · 2.15 KB

3rdpartyprompts.md

File metadata and controls

43 lines (27 loc) · 2.15 KB

How to configure 3rd party prompts

nerdfonts

nerdfonts are not required but they make the presentation much better.

site

repo

oh-my-posh

site

repo

If you like oh-my-posh, you can use oh-my-posh with Nushell with a few steps. It works great with Nushell. How to setup oh-my-posh with Nushell:

  1. Install Oh My Posh and download oh-my-posh's themes following guide.
  2. Download and install a nerd font.
  3. Set the PROMPT_COMMAND in ~/.config/nushell/config.nu, change M365Princess.omp.json to whatever you like Themes demo.
> let-env PROMPT_COMMAND = { oh-my-posh --config ~/.poshthemes/M365Princess.omp.json }

Starship

site

repo

  1. Follow the links above and install starship.
  2. Install nerdfonts depending on your preferences.
  3. Set the starship shell environment variable to nu by running this commend let-env STARSHIP_SHELL = "nu"
  4. If you want the default ticking clock with date & time on the right prompt execut this command hide PROMPT_COMMAND_RIGHT
  5. If you don't want the default indicator, you can run this command let-env PROMPT_INDICATOR = " "
  6. Set starship as your left prompt with this command let-env PROMPT_COMMAND = { starship prompt --cmd-duration $env.CMD_DURATION_MS --status $env.LAST_EXIT_CODE | str trim }. Note that you may not have to use str trim in the Nushell prompt if you disable starship's default newline setting with this entry in the starship.toml file add_newline = false. There have been reports that this might not play nice with Nushell prompts. We're still testing.
  7. Since Nushell supports a right prompt you can also play around with starship's ability to set a right prompt. Setting the right prompt in Nushell is identical to setting the left prompt however you use PROMPT_COMMAND_RIGHT.

Purs

repo