-
Notifications
You must be signed in to change notification settings - Fork 23
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
Allow automatic UI/CLI toggle setting #33
Comments
There has been some discussion about this here. |
Ah ok, I missed that! To give some more insight into why it would be useful (for me): |
Running the GUI if no parameters are passed in, might actually work well, I will have to prototype it. |
First of all, very cool lib!
It would be nice to have some way to decide whether or not the GUI should be launched based on some flag.
The usecase is that distributing a tool with klask will have the benefit of having a nice CLI in case people want to automate it, or use it in scripts, but people using it less often or who aren't comfortable with the CLI get greeted with a nice GUI.
I think it could be something along the lines of: if no additional arguments are present, start the gui, otherwise run the function in
run_derived
with the args parsed from what the program has been invoked with. This will however have the requirement that the program takes at least one required parameter, because otherwise you cannot distinguish between a CLI invocation and an invocation to start the GUI, but that is a trade-off tool-authors will have to consider then.The text was updated successfully, but these errors were encountered: