if you want to use python together with dialog to build cli menus, i recommend using http://pythondialog.sourceforge.net/doc/. i've been using it for a project at work and it's very nice!
This is really nice. I'm working on a similar project right now, trying to hook together a few console UI pieces like this into a coherent annotation tool:
Thanks for the feedback! Will definitely add more features to this package. Wrapping up several prompts together is a great idea too, thanks for the insight.
Might be useful to handle deactivated choices (ie greyed out).
It looks like it handles multi choice (with the check feature), but can it do validation upon a check being selected or does it need to wait until the user has made their choice? Am thinking for catching invalid combinations.
do you know of an other package that does this? just yesterday and this morning I was looking for something like this but I could've sworn there's a more modern package. I just can't seem to find the right Google keywords to land on it.
edit: and in particular for click. i didn't realize gooey was for arg parse
termios issue. I installed this via pip in python 3.7 under windows 10 and got an error about the termios package not being available. But trying to install termios via pip reports that the package is not available.
Any suggestions?
i'd say "beautiful" in this context is shorthand for "built with attention towards aesthetics", which is often not the case for programmer tools like this
What are the use cases? This looks like a fun project without any real applications. A react component makes sense because it hooks into an existing ecosystem but how would something like this get used in an existing cli?
Edit: React has an ecosystem for things like this. Cocoa/Obj-C has an ecosystem for things like this. Tiny single purpose UI elements. Python does not have this because there is no UI framework for doing console applications that doesn’t already provide this capability as part of a batteries included tool.
I don't quite follow you here. It is a library for making some simple UI for command line applications.
If you have a command line application in python you could implement this for fancier list selections.
I'm unclear on how you relate this to React components. Python libraries have been part of an existing ecosystem long before React. The python ecosystem.
I can think of a lot of simple scripts that I could easily plug this into. When I’m writing a little script to do something for me, the last thing I want to do is write any sort of UI
Can’t tell if you’re being sarcastic or not. Your above sample code is perfectly simple and straightforward. I would choose it over an over engineered ui library/dependency in a heartbeat.
http://www.unixcl.com/2009/12/linux-dialog-utility-short-tut...