ohmyzsh: Breezy causes zsh to hang
Describe the bug With Breezy installed on Debian Bullseye the zsh prompt might hang while waiting for breezy to show the commit revision. (git-status)
Additionally within bigger git repositories breezy will hang for enormous amounts of time and produce a git revision like this:
master bzr@revision-id: git-v1:0xvery_long_shasum
To Reproduce
- Either use a theme with git status or enable git-prompt (bzr-prompt)
- Clone a bigger repository or use oh-my-zsh
- Chdir into that folder
- Wait for the prompt
- Bonus: see some useless information
Expected behavior within a git repository do not call bzr and do not show its output
Screenshots or recordings
System:
- OS: Linux (Debian Bullseye)
- Zsh version 5.7.1
- Gnome-Terminal
Additional context It seems that breezy will provide a bzr and brz binary. I guess it is a drop in replacement for Bazar that additionally supports git.
I could fix the issue with uninstalling breezy, but there might be people out there who use that versioning tool and their experience will be really bad.
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Reactions: 2
- Comments: 20 (7 by maintainers)
This just started happening to me as well. My Arch install updated
breezy(replaced a conflicting module) than suddenly/usr/bin/bzrwas on the systemPATHand I got the hanging prompt whencd’ing to a directory that contains a git repo. I’m using a slightly modified version of the Agnoster theme that I keep in sync with the original. By removing theprompt_bzrroutine from the theme I can avoid the hanging. Anyone using Agnoster out of the box will be affected by this Breezy bug.The agnoster theme bundled in OMZ strays very far from the official one and is in need of a big revamp. That said, this changed
prompt_bzrfunction may fix your issue until we refactor the agnoster theme (copy-paste it to the terminal and enter a git repository):Just ran into this after upgrading to Pop!_OS 20.04.
Commenting out
prompt_bzrin the oh-my-zsh Agnoster theme’sbuild_prompt()function seems to have solved it. (I also commented outprompt_hg.Sounds like a huge waste of resources to me, surely a simple
if [ -d .git ]would be lighter (and certainly smarter) than runninggit statuseverywhere. For instance prezto only runs git and bzr commands where it makes sense, haven’t had any issue with git repositories since the breezy switch.