geometry-zsh / geometry

geometry is a minimal, fully customizable and composable zsh prompt theme
ISC License
921 stars 94 forks source link

Can't type after a fresh install #241

Closed gtarraga closed 4 years ago

gtarraga commented 5 years ago

Just installed the theme and displayed the initial prompt but it doesn't let me type at all, I'm running it in Cmder and looks like I can't close the window either. I tried with a fresh install a couple times but still didn't work.

I'm running Zsh on mintty and all that on Cmder, Windows 10 image

jedahan commented 5 years ago

Can you share your entire .zshrc ?

gtarraga commented 5 years ago

Here you go.


ZSHRC_DIRECTORY=${${(%):-%N}:A:h}
[[ -f $ZSHRC_DIRECTORY/.profile ]] && . $ZSHRC_DIRECTORY/.profile

# Path to oh-my-zsh and antigen installation.
export ZSH=$HOME/.oh-my-zsh
source $ZSH/antigen.zsh

antigen theme geometry-zsh/geometry

# # Theme
# ZSH_THEME="geometry"

COMPLETION_WAITING_DOTS="true"

precmd() { print "" }

plugins=(
  git
  npm
  vscode
  zsh-autosuggestions
  zsh-syntax-highlighting
)

# zsh-autosuggestions
ZSH_AUTOSUGGEST_BUFFER_MAX_SIZE=10
ZSH_AUTOSUGGEST_HIGHLIGHT_STYLE='fg=0'
zle -N autosuggest-execute
bindkey '^ ' autosuggest-execute

# Enable custom aliases, syntax highlighting && launch.
source ~/.aliases
source ~/.oh-my-zsh/custom/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
source ~/.oh-my-zsh/oh-my-zsh.sh

export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"  # This loads nvm
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion"  # This loads nvm bash_completion```
jedahan commented 5 years ago

Can you confirm that just loading geometry.zsh with nothing else (no plugin manager, no antigen) still exhibits the behaviour. Sorry if its tedious but I don't have a windows box to test this on.

I got a gut feeling that we are not handling the precmd() override but thats just a hunch

jedahan commented 5 years ago

I'll try this zshrc on my laptop and see if it replicates that behaviour as well

jedahan commented 5 years ago

To be more clear, try this as your entire ~.zshrc

# ~/.zshrc
test -d ~/.geometry || git clone https://github.com/geometry-zsh/geometry.git ~/.geometry
source ~/.geometry/geometry.zsh
jedahan commented 5 years ago

@gtarraga any update?

gtarraga commented 5 years ago

Sorry about the delay. Just tried using the ~/.zshrc file you suggested, I'm still not able to type on the console once the theme is active.

jedahan commented 5 years ago

What is the output of zsh --version?

gtarraga commented 5 years ago

The output is zsh 5.5.1 (x86_64-unknown-cygwin)

jedahan commented 5 years ago

Ok I am at a complete loss The two things I can think of are

shinmai commented 5 years ago

This happens for me when async prompt is enabled. Trying the mnml branch, with async enabled I get occasional geometry::rprompt::set:3: failed to close file descriptor 11: bad file descriptor errors. The master branch works fine with async disabled, but with the obvious drawback that the prompt takes a solid second and change to appear when navigating inside a git repo.

jedahan commented 5 years ago

I am getting this error as well now, on ubuntu 18.04

jedahan commented 5 years ago

I have a fix inspired by https://github.com/zsh-users/zsh-autosuggestions/blob/master/src/async.zsh , will push tonight

jedahan commented 5 years ago

@shinmai can you try the latest version?

jedahan commented 4 years ago

Feel free to re-open if its still an issue.