I made this simple command interpreter for a work project. It's so simple that I think there are probably dozens or hundreds of things like this out there.
I'm hoping to get some feedback on the code, recommendations for making it better while maintaining its feature-set and simplicity. I'd like to improve my coding skills and I think feedback is probably the best way for me to do that.
I do have some specific questions:
- how would I implement type-hinting in this?
- What other functionality needs to find its way into the interpreter? One of the things I've been thinking about is command flags + args. Right now resolving that will be up to the user, but I think we might be able to do something clever with dict/tuple unpacking.
I also hope this can be useful for others.
(If this reeks of 'list parser', there's a reason. :D)
I'm hoping to get some feedback on the code, recommendations for making it better while maintaining its feature-set and simplicity. I'd like to improve my coding skills and I think feedback is probably the best way for me to do that.
I do have some specific questions:
- how would I implement type-hinting in this?
- What other functionality needs to find its way into the interpreter? One of the things I've been thinking about is command flags + args. Right now resolving that will be up to the user, but I think we might be able to do something clever with dict/tuple unpacking.
I also hope this can be useful for others.
(If this reeks of 'list parser', there's a reason. :D)