starship: Starship not loading using init zsh
Current Behavior
I don’t see the starship prompt. I only see the default zsh prompt.
Expected Behavior
I should see the starship prompt instead of the default zsh prompt.
Additional context/Screenshots
I tested this on an archlinux container. My issue is similar to https://github.com/starship/starship/issues/2508 but it doesn’t apply to me since my .zshrc is only one line.
Even if I’m still using zsh as my shell, creating this .bashrc would show the starship prompt.
eval "$(starship init bash)"
I also tested installing from the package manager and through curl -fsSL https://starship.rs/install.sh | bash
Possible Solution
Environment
- Starship version: 0.51.0
- zsh version: 5.8 (x86_64-pc-linux-gnu)
- Operating system: Arch Linux Unknown
- Terminal emulator: termite v15
- Git Commit Hash: 88c3844d
- Branch/Tag: v0.51.0
- Rust Version: rustc 1.50.0
- Rust channel: release
- Build Time: 2021-03-25 14:52:19
Relevant Shell Configuration
# cat .zshrc
eval "$(starship init zsh)"
Starship Configuration
<unknown config>
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Reactions: 7
- Comments: 16 (5 by maintainers)
@mahor1221 Better yet, running
prompt offbefore starship’s init will also work to disable grml’s prompt functionality in favor of Starship’s.With the release of v0.51.0, we updated Starship to only set
$PROMPTonce, at initialization, whereas we would previously re-set it every render.This means that shells that were previously having their Starship prompt overridden would later be re-overridden by Starship. As a result, previously misconfigured prompts that shouldn’t have worked are now no longer working.
removed
grml-zsh-configand it worked but in 0.50.0 we didn’t need to comment out anything. it just worked out of the boxif anyone else using it comment out these lines:
Adding
prompt offbefore theeval "$(starship init zsh)"line fixed the issue for me.Are you using something like
grml-zsh-config? If you are, then a quick workaround is to manually remove or comment out the lines that set the prompt in/etc/zsh/zshrc.