Closed alexprengere closed 11 years ago
I shipped this feature on the develop
branch, and this is also available on GeoBasesDev channel.
The original idea has been used, here is an example:
$ GeoBase --ask # or -a
-----------------------------------------------------
WELCOME TO LEARNING MODE
You will be guided through the
possibilities by answering a few
questions.
-----------------------------------------------------
[1/5] Which data source do you want to work with?
[2/5] Consider all data for this source [Y/N]? Y
[3/5] What kind of filter?
[4/5] On which field?
[ ] Which value to look for?
[5/5] Which display?
-----------------------------------------------------
Equivalent one-liner command
with long options and short options
Run it!
GeoBase --base airlines --fuzzy-field name --fuzzy "air asia" --quiet
GeoBase -b airlines -F name -f "air asia" -q
-----------------------------------------------------
The user is guided through some questions, and at the end he gets the command to run.
I think it would be interesting to have a interactive mode where you just answer questions like:
Some additional questions may be asked if necessary. At the end, the query is run, and the user get the one-liner he could have typed to get it directly.
I believe this could make the CLI more accessible for new users, and provide a way to learn and understand it.
Concretely: