whole-foods-deliverance icon indicating copy to clipboard operation
whole-foods-deliverance copied to clipboard

GUI

Open mark-thompson opened this issue 4 years ago • 4 comments

Might be nice to have a graphical option for setting config as well as control flow for those who don't spend all day in fancy text editors or on the command line.

mark-thompson avatar Apr 24 '20 02:04 mark-thompson

There's a project called Gooey that should be an easy way to pass arguments via GUI. I should have some time this weekend to give it a shot

eoprede avatar Apr 26 '20 01:04 eoprede

@eoprede Neat find - seems like a very convenient tool to convert the argparse things into a decent looking dialog box. Not sure how well it solves the config options (specifying slot times, for example) and control flow issues though. I'm thinking Flask may make sense here, or something more 'traditional' like tkinter

mark-thompson avatar Apr 26 '20 02:04 mark-thompson

@mark-thompson My preliminary thoughts - if user runs script with no args, check whether Gooey is installed and if yes - launch Gooey. If no Gooey or args provided - go to CLI version. Cli version takes config values from file, Gooey version has some additional options. Those options can include listboxes for time selection (here's an example of how they look - https://github.com/chriskiehl/Gooey/issues/228 ), preferred credit card, etc. Then just pass those values to the rest of the script or fall back to what's configured in the file.

eoprede avatar Apr 26 '20 03:04 eoprede

With that said though, users still would have to make sure python is installed, run pip commands, activate venv (or maybe not bother with it and just install all the libraries) - I almost want to say that if they are willing to put up with all that for the convenience of automatically ordering food, then they might as well edit config files...

eoprede avatar Apr 26 '20 03:04 eoprede