dthree / vorpal

Node's framework for interactive CLIs
http://vorpal.js.org
MIT License
5.63k stars 278 forks source link

Permit autocomplete options #295

Closed AdrieanKhisbe closed 6 years ago

AdrieanKhisbe commented 6 years ago

So far user defined autocomplete function will not be called when trying to complete the arguments of a given options.

In case of allowUnknownOptions, it would be useful that the autocomplete function takes care of the flags completion.

This is the need I have for building vorpal-shell to have in cli completion of options.

Maybe other design option can be considered such as a property handlesOption in the autocomplete option along with the function data. I'm open to that :)

AdrieanKhisbe commented 6 years ago

Great @milesj ! Thanks à lot !

Do you think it can be shipped on a minor or patch version ? Or should i wait thé major 2.0 to Land? :)

milesj commented 6 years ago

Not sure. I don't have access to publish.

AdrieanKhisbe commented 6 years ago

Ah ok 😕 Do you think you could do something @dthree ? 😃