-
Notifications
You must be signed in to change notification settings - Fork 203
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
zsh completion does not allow directories to be tab-completed #414
Comments
$ dust --version
Dust 1.0.0 |
After a quick investigation it seems like the fix is not in any official release yet thus missing from most pkg managers. I fixed the problem locally now and do not mind creating a PR to patch
|
Sadly a re-occurring problem. Whenever anyone rebuilds the completions file it seems to destroy the fix for zsh completion. Does your fix look like this ? |
$ git diff completions/_dust index ecf5150..8745356 100644
--- completions/_dust
+++ completions/_dust
@@ -19,10 +19,10 @@ _dust() {
'--depth=[Depth to show]: : ' \
'-n+[Number of lines of output to show. (Default is terminal_height - 10)]: : ' \
'--number-of-lines=[Number of lines of output to show. (Default is terminal_height - 10)]: : ' \
-'*-X+[Exclude any file or directory with this name]: : ' \
-'*--ignore-directory=[Exclude any file or directory with this name]: : ' \
-'-I+[Exclude any file or directory with a regex matching that listed in this file, the file entries will be added to the ignore regexs provided by --invert_filter]: : ' \
-'--ignore-all-in-file=[Exclude any file or directory with a regex matching that listed in this file, the file entries will be added to the ignore regexs provided by --invert_filter]: : ' \
+'*-X+[Exclude any file or directory with this name]:ignore directory:_files' \
+'*--ignore-directory=[Exclude any file or directory with this name]:ignore directory:_files' \
+'-I+[Exclude any file or directory with a regex matching that listed in this file, the file entries will be added to the ignore regexs provided by --invert_filter]:ignore all in file:_files' \
+'--ignore-all-in-file=[Exclude any file or directory with a regex matching that listed in this file, the file entries will be added to the ignore regexs provided by --invert_filter]:ignore all in file:_files' \
'-z+[Minimum size file to include in output]: : ' \
'--min-size=[Minimum size file to include in output]: : ' \
'(-e --filter -t --file_types)*-v+[Exclude filepaths matching this regex. To ignore png files type\: -v "\\.png\$" ]: : ' \
@@ -72,7 +72,7 @@ _dust() {
'--help[Print help]' \
'-V[Print version]' \
'--version[Print version]' \
-'*::params:' \
+'*: :_files' \
&& ret=0
} Basically stole some stuff from #390 and applied them to I did it for myself as a tmp solution until your next release but then decided to share so you can have a quick patch for Anyways, I noticed you released Thanks for taking a look! |
Seems to be working as expected. Tested with |
I am experiencing the same issue as described in #359:
The original issue was resolved in #390 so I am not sure if it is me that is doing something wrong but I do not have any other zsh completion ATM.
Moreover, the completion of
--<option>
works as expected so it is only the paths that are not getting completed.I am using Macbook with
M3 Pro
but tested this on a Macbook withIntel i9
and it has the problem.The text was updated successfully, but these errors were encountered: