New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
etc/zprofile is being called twice causing CHERE_INVOKING to fail. #205
Comments
An update: I started mintty without the trailing dash. That was able to resolve the issue, confirming my suspicion mentioned above. For some reason, the startup in login mode is causing the /etc/zprofile to execute twice. |
/etc/zshrc executes after /etc/zprofile. You are sourcing 3 files from /etc/zshrc. Amongst them, babun.zsh is sourcing /etc/zprofile again. So, your execution flow is: /etc/zprofile -> /etc/zshrc -> /usr/local/etc/babun.zsh -> /etc/zprofile. I hope you can fix the same now. |
Thanks for the thorough analysis! |
Fixed in 1.1.0. |
This still seems to be an issue. With babun 1.1.1 I got a following startup log
So the execution is still Unfortunately - besides tracing that I have no idea how to approach the change (and the implications). I was using
|
One more thing. This happens when I run babun from the shortcut However, if I click already open icon and run
Having traced that (obviously by accident) I'm rather lost with what's going on but I hope smb will find it helpful (feels like tester ;>) |
Hi! I set CHERE_INVOKING=1 in babun.bat similar to what we do for standard cygwin installation for starting the shell in current dir. It didn't work. I tried installing chere package too, but was unsuccessful to start Babun in current dir. On further hacking/debugging, I found that the issue may be due to /etc/zprofile being called twice (I observed that it was called twice when I added an echo statement to the file). It deletes the variable after running the first time, so on the second time, the variable won't be available and it does a cd to ${HOME}. I believe that if you can prevent /etc/zprofile from running twice on startup, it will resolve the issue.
The text was updated successfully, but these errors were encountered: