Very slow in home folder because of VCS prompt segment #244
Comments
What I do is I make a |
@dj-hedgehog Thanks for the report. The way @jguenther suggests would work. But I don't like it that this theme slows your terminal that much down. So I create a repository with 500.000 untracked files, and voilá it is slow as hell. |
Bad news: This is an issue of git itself. My first thought was, to cut off the response of git (with IMHO there are two ways that would work:
But apart from that, all we could do is sending a patch to git.. |
@dritter - What are your thoughts on moving the dirty check into a |
Hmm. The only way how I imagine these precmds are executed are:
I think there is no faster way than doing it like we do (except for the async way). Best would be submitting a PR to git, adding a new command that will stop right after a valid (considering the |
@dritter - Thanks for the thoughts! Hm... maybe I'll look into what it would take to do that check asynchronously, as the project did in your link. That would be pretty cool, but it sounds like the workload might be... heavy. |
@dritter |
@chenjuntong This is strange. Do you have a huge repository as well? Or does this happen in any repository (even small ones)? |
@dritter This happen in any repository.When using powerlevel9k, the entire zsh seems slow down. Even simple command like "cd" is slower too. Extremely slow when using vcs. Therefore whether I operate on local folders(which I operate on) or network-mounted folders it is the same. |
@chenjuntong That is strange. The Are your repositories git or mercurial ones? (Git should be faster than mercurial). And how fast is the invocation of |
@dritter My repositories are git ones. |
Yeah, there seem to be some speed issues with ZSH's If anyone else is interested in contributing on this front, I consider this to be an important effort. |
I've made the RPROMPT async based on this blog post. You can see the changes at master...andjscott:master if interested. |
@andjscott I am sorry that this solution hasn't completely solve the problem. It maybe a little faster than the original config. Still, every command slower when using the VCS_INFO. |
|
@andjscott Only accidental. :D We had some trouble getting the Btw. the async prompt looks awesome! Thank you very much! |
Work continues in #263... |
@chenjuntong try |
@andela-oadesanya - Wow, really? Do you know what version ships with OSX by default, and what version of git you have now? |
@bhilburn Apple ships |
@andjscott @andela-oadesanya @bhilburn "removing-zle-functions: https://github.com/bhilburn/powerlevel9k/tree/removing-zle-funcs" has solved this problem. Thank you! |
@chenjuntong - Happy to hear that! We'll get that merged into master soon. |
I turned my home-folder
~
into a dotfiles repository with a lot of untracked files.Ever since I made this change zsh is unusable slow while I'm located in the home-folder. It takes like 5-10 seconds to register keystrokes or execute anything.
Since I like the VCS segment I'd like to know what I can do about it without removing it entirely? Can I disable it in certain folders or is there some git function I can use?
The text was updated successfully, but these errors were encountered: