sorin-ionescu / prezto

The configuration framework for Zsh
MIT License
13.87k stars 4.49k forks source link

Setting prompt to sorin disconnects my shell #1137

Open aliostad opened 8 years ago

aliostad commented 8 years ago

Hi,

I have been using your great work through yadr and happily using sorin as my default prompt (and I love it). This has been working fine for me but today I was setting up a new Linux box and changing the default prompt (by editing zzzz_after.zsh in ~yadr/zsh) or creating a new file in .zsh.after and my zsh seems to be crashing and I get disconnected from the ssh.

As I said, this was working fine in previous machines I have set up. I am no linux god or anything like it, happy to report back any log, etc you need.

Thanks for a great project.

PS: I tried oliver and it worked. It seems it is only sorin (ironic isn't it) which has a problem.

aliostad commented 8 years ago

Sorry no solution have been found yet. Can anybody respond?

meastes commented 8 years ago

I have the same issue. It only happens over SSH. It appears to be related to the async process. It seems that the "zle reset-prompt" command is crashing my SSH session for some reason.

UPDATE: This is the same issue - https://github.com/zsh-users/zsh-autosuggestions/issues/126 A workaround is to change the 'zle reset-prompt' command to 'zle .reset-prompt'

rjcoelho commented 7 years ago

Same problem when using sorin in Visual Studio Code Integrated Terminal. And @meastes 's suggested workaround worked for me.

--- a/modules/prompt/functions/prompt_sorin_setup
+++ b/modules/prompt/functions/prompt_sorin_setup
@@ -57,7 +57,7 @@ function prompt_sorin_git_info {
     _prompt_sorin_precmd_async_pid=0

     # Redisplay prompt.
-    zle && zle reset-prompt
+    zle && zle .reset-prompt
   fi
 }
belak commented 6 years ago

Are you still seeing this with the latest changes? We've updated how the async process works with the sorin prompt.