A simple python command shell, that allows you to wrap your program in a interactive shell environment.
Use the package manager pip to install CShell.
pip install qshellThe docs will be available soon :) for now just check out the examples folder to see how its used!
The barbones example:
from qshell import Shell, register
commands = {}
@register('echo', 'Echo a word back to the console', 'Usage: echo sometext', commands)
def command_echo(shell, user_in):
return " ".join(user_in[1:])
def main():
example = Shell(commands)
example.run()
- Add environment variables
- Create Documentation
- Better error handling
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
Please make sure to update tests as appropriate.
