-
-
Notifications
You must be signed in to change notification settings - Fork 25.9k
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
Agnoster theme prompt extremly slow in mercurial #4116
Comments
FYI, if you're going to link to lines of code (or files for that matter) in a bug report, you should link to a specific commit, instead of "master" or another branch name. Otherwise, later commits may shift around line numbers and your link will be pointing at a different piece of code. (For example, we're about to merge a commit to |
@apjanke thanks for advice |
How slow is "extremely slow" for you? This stuff is all relative. :) I'm trying it out on OS X 10.9.5 Mavericks, on an SSD MacBook Pro. In a newly created Hg repo, it feels like it takes between half a second and a second to issue the prompt. That feels pretty slow to me. But is also not a huge surprise: this is not a very fast theme, and it's doing This could maybe be improved by consolidating the |
Oh, yeah, we can totally speed this up. Half those |
I did a quick fix for this, but it is not so functional. However, probably it will help
By the way, I switched my console to https://github.com/bhilburn/powerlevel9k witch is way more fast from-the-box |
Thanks! Interesting. PowerLevel9K is relying entirely on |
@apjanke Jep. |
Oh, nice. I see some |
Agnoster now has its own repo, https://github.com/agnoster/agnoster-zsh-theme, and is using Zsh |
Well, its not slow anymore, but it neither shows hg info in zsh prompt =) Built-in agnoster theme is still slow in hg repo. I am happy with powerlevel9k theme by the way |
Oh yeah, the |
Will this improve anytime soon? I'm having similar issues with bullettrain (which is based on agnoster). |
Steps to reproduce: hg clone https://hg.mozilla.org/mozilla-central
cd mozilla-central
time (prompt_hg > /dev/null)
# ( prompt_hg > /dev/null; ) 2.77s user 1.19s system 99% cpu 3.971 total |
The lag stems from the three calls to hg clone https://hg.mozilla.org/mozilla-central
cd mozilla-central
time hg id
# hg id 0.66s user 0.35s system 99% cpu 1.020 total
time hg id -n
# hg id -n 0.65s user 0.38s system 99% cpu 1.032 total
time hg id -b
# hg id -b 0.08s user 0.03s system 99% cpu 0.117 total
time hg st
# hg st 1.32s user 0.41s system 99% cpu 1.733 total |
In theory, there is some potential:
In practice, this does improve the situation only slightly:
|
Wow, using Any drawbacks? I guess it is only available on the latest hg versions? Update: I realized that a ~12MB Python process has to be kept running in background (but I guess I don't mind) |
@maelvalais What version of |
Looks like it is https://www.mercurial-scm.org/wiki/CHg (afaik, not shipped with mercurial) |
Ahh... I just noticed that this Unfortunate that it is not shipped by default... |
I have disabled the status in mercurial repositories now by adding |
The agnoster theme still seems to be really slow in Mercurial repos. I tried the custom repo of anoster, which out of the box was no better. So let's give powerlevel9k a try. ohmyzsh/ohmyzsh#4116
Hi! Is there any news about this issue? I have the exact same problem with firefox repository with agnoster theme prompt. |
Just checking in, I'm experiencing the same problem with agnoster theme and the mozilla unified repository... |
Is there a way to disable mercurial prompt just for a repository? Similar to |
Going to close this and assume any edgecases can be sorted with a per-project workaround |
Code here https://github.com/robbyrussell/oh-my-zsh/blob/3d2bf227ea2b37d351ac3846627f28151e0a4480/themes/agnoster.zsh-theme#L111 runs very slow (mac yosemite)
The text was updated successfully, but these errors were encountered: