Conversation
kachick
commented
Aug 2, 2023
| local -r dump_dir="${config.xdg.cacheHome}/zsh" | ||
| local -r dump_path="$dump_dir/zcompdump-$ZSH_VERSION" | ||
|
|
||
| if ${lib.getExe pkgs.fd} --quiet --changed-within 6hours "$dump_path"; then |
Owner
Author
There was a problem hiding this comment.
fd is much slow for this purpose 🙄
Owner
Author
|
180~250ms => 60ms 😂 |
Owner
Author
|
Extracted the docker completion error in first time has been extracted as #236 |
kachick
commented
Aug 2, 2023
| # https://github.com/nix-community/home-manager/blob/8c731978f0916b9a904d67a0e53744ceff47882c/modules/programs/zsh.nix#L368-L372 | ||
| # The default is "autoload -U compinit && compinit", I can not accept the path and speed | ||
| initExtraBeforeCompInit = '' | ||
| _elapsed_seconds_for() { |
kachick
commented
Aug 2, 2023
| compinit -C -d "$dump_path" | ||
| else | ||
| mkdir -p "$dump_dir" | ||
| compinit -d "$dump_path" |
Owner
Author
There was a problem hiding this comment.
Without cache as here, still taking 160~180ms
Owner
Author
|
Almost 50~60 ms for all bash, zsh, fish in WSL2 Almost 120~170ms in my macbook pro 2018 model 🤮 |
Merged
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #222
Updates kachick/times_kachick#184
May again #155