-
-
Notifications
You must be signed in to change notification settings - Fork 28
Separate module "inquirer" & "commander" from cmd.js file #32
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
Comments
May I propose a way to structure this code: There are 5 parameters needed before the parser can run:
Each parameter can be obtained from a list of sources, which currently include command line options and user response from an interactive prompt. In the future we could add the ability to read values from a configuration file or even a GUI dialog like with dialog-node. So Each information source would be defined in its own file, which has some initialization code and exports a function which takes in the parameter specification (name, description, type, filter, etc), and returns a Promise which either resolves to the parameter value or rejects. An information source could have special cases, for example the Finally, since the role of |
Hi @hagabaka , thank you so much for your help on this topic. I will try to put this in place asap. |
Hi, the application only need 4 parameters :
In fact, there is no real sub-category. With inquirer, we ask for a "sub"-category only when |
- Split commander and inquirer modules (fix dofapi#32) - Clean code & add some comments
For better clarity in the file, we should split cmd.js file into to files.
The text was updated successfully, but these errors were encountered: