4 ms·
I've been a unix user for more than 2 decades now and have seen many of projects like these. And I've dismissed all for the simple reason that they don't fix th
by jlg23 5y ago
I've been a unix user for more than 2 decades now and have seen many of projects like these. And I've dismissed all for the simple reason that they don't fix the problem at its roots: getopt et al should be instrumented to provide valid completions for all unix commands. A layer on top is destined to be out of sync with the actual implementations soon. We only get one more level of indirection, one more abstraction layer that can go wrong. I simply don't get it.
- mschrage 5y agoTotally agree! The closer autocompletion lives to the source code, the better. We've started off writing completions by hand, but to scale we will need more robust integrations. For instance, aws has 100+ subcommands and thousands of options. Long term, we plan on writing integrations with popular CLI libraries, so that the completion spec can be generated automatically. We've already started with oclif[0] and have done some preliminary work with cobra. [0 https://github.com/withfig/oclif-plugin/blob/main/src/commands/fig-completion.ts https://github.com/withfig/oclif-plugin/blob/main/src/comman...]