duf icon indicating copy to clipboard operation
duf copied to clipboard

bash/zsh command line completion

Open yermulnik opened this issue 3 years ago • 5 comments

Would be super great to have bash/zsh completion (to complete mount paths and to complete command line args and their respective values) bundled into a duf binary to be used like (bash example) complete -C /usr/local/bin/dif duf. Thanks in advance.

yermulnik avatar Nov 01 '20 12:11 yermulnik

Integration like this ? https://gist.github.com/icholy/5314423

IGLOU-EU avatar Feb 21 '21 00:02 IGLOU-EU

We're using cobra for flag handling, but it can just as easily create completions for us.

Edit: Scratch this, I'm obviously wrong and we're not using cobra for flag handling here :laughing: Which actually makes this a bit harder to solve. I'll look into your gist, @IGLOU-EU.

muesli avatar Jul 04 '21 01:07 muesli

At this point we should probably switch to https://github.com/muesli/coral so we get completions and man page generation for free.

muesli avatar Feb 07 '22 03:02 muesli

I don't know if I should have created a new issue for this but I use fish and I'd like fish completions.

Because it has been months and no completions have been added yet, I would like to write fish completions myself and submit a PR if that's OK.

realmazharhussain avatar Jul 10 '22 06:07 realmazharhussain

At this point we should probably switch to https://github.com/muesli/coral so we get completions and man page generation for free.

do that pls

jpx40 avatar May 22 '23 18:05 jpx40