Vi-mode functionality is maintained but mode transition from _normal_ to _insert_ no longer displayed correctly and [I] is always shown in both mode.
If I run spaceship_vi_mode_enable the functionality resumes to be shown correctly.
I opened an issue also in prezto-contrib belak/prezto-contrib#9
Spaceship version: 3.0.1
Zsh version: 5.3.1
Zsh framework: Prezto
Zsh plugin manager: None
Terminal emulator: Termite
Operating system: Debian 9.4
.zshrc
SPACESHIP_PROMPT_ORDER=(
time # Time stampts section
user # Username section
host # Hostname section
git # Git section (git_branch + git_status)
battery # Battery level and status
vi_mode # Vi-mode indicator
jobs # Backgound jobs indicator
char # Prompt character
)
SPACESHIP_RPROMPT_ORDER=(
exec_time # Execution time
dir # Current directory section
aws # Amazon Web Services section
ruby # Ruby section
haskell # Haskell Stack section
php # PHP section
)
export SPACESHIP_PHP_SYMBOL=' '
export SPACESHIP_RUBY_SYMBOL='îž‘ '
Thanks,
Mauro
Do you have the editor module enabled in prezto ?
Possible explanation :
Vanilla Zsh don't set the zle-keymap-select special widget. This widget is responsible for identifying KEYMAP. Since it's not defined, prompt is displaying the value it's assigned on initialization.
Popular Zsh frameworks have this as extension. In prezto it's handled with editor module and OMZ has the vi-mode plugin.
In my initial experiments, I wasn't able to get this working even with the editor module enabled because $KEYMAP is only valid inside a zle widget.
prezto sets $editor_info[keymap] as seen in editor-info widget (which is hooked up to zle-keymap-select, as you mentioned). I'm not sure how oh-my-zsh handles this.
EDIT: Let me take a closer look at this on the prezto side. I'm guessing that we aren't calling zle reset-prompt correctly.
This was an issue in prezto with a workaround we put in place for a different prompt. I don't know if there's a good way to fix it perfectly, so I reverted the hack and it seems to be fixed with spaceship.
Thanks, problem solved with @belak fix in prezto.
Relevant commit from prezto : https://github.com/sorin-ionescu/prezto/commit/054eb351f1d7d92d810259e3a5fbfd9e025b2d08
Hi there, I have been experiencing the same issue with the following versions:
Spaceship version: 2.9.0/3.8.2/4.0 (Changed by checking out branches/tags)
Zsh version: 5.6.2
Zsh framework: oh-my-zsh(?)
Zsh plugin manager: oh-my-zsh(?)
Terminal emulator: GNOME Terminal 3.28
Operating system: CentOS 7
Please let me know if you would like me to create a separate ticket for it and whether you need more info.
Regards,
Dawid
I have also tried Zsh 5.3.1
This is also something I get when I try to lunch zsh from bash:
/home/dawid/.oh-my-zsh/custom/themes/spaceship.zsh-theme:321: parse error near `&&'
It does seem to work when I set zsh default shell in my terminal though.
This is also something I get when I try to lunch zsh from bash:
You might have multiple versions of Zsh installed. One used launched from bash might be different from the one configured as default shell. Check them with which $SHELL and which zsh. Better to open new issue if not resolved.
Most helpful comment
Thanks, problem solved with @belak fix in prezto.