summaryrefslogtreecommitdiffstats
path: root/gamechestcli/__main__.py
diff options
context:
space:
mode:
authorvg <vgm+dev@devys.org>2022-09-18 20:23:17 +0200
committervg <vgm+dev@devys.org>2022-09-18 20:23:17 +0200
commit21908c97c1e897554751070d08e2b35694529bc0 (patch)
tree7435287f77e165a343134a152a1b8ff2b0f964ee /gamechestcli/__main__.py
parentf02ba5ad748b9cbad129274aecb5b26d3ce3a2ba (diff)
downloadgamechest-21908c97c1e897554751070d08e2b35694529bc0.tar.gz
gamechest-21908c97c1e897554751070d08e2b35694529bc0.tar.bz2
gamechest-21908c97c1e897554751070d08e2b35694529bc0.zip
git-sync on seele
Diffstat (limited to 'gamechestcli/__main__.py')
-rwxr-xr-xgamechestcli/__main__.py28
1 files changed, 28 insertions, 0 deletions
diff --git a/gamechestcli/__main__.py b/gamechestcli/__main__.py
new file mode 100755
index 0000000..1497e40
--- /dev/null
+++ b/gamechestcli/__main__.py
@@ -0,0 +1,28 @@
+#!/usr/bin/python3
+'''
+Manage games. Install, remove, run them.
+
+Usage: gamechest install <GAME_ID>
+ gamechest remove <GAME_ID>
+ gamechest run --profile_id=<PROFILE_ID> <GAME_ID>
+'''
+
+import docopt
+
+from gamechest.cliactions import install, remove, run
+
+
+def main():
+ args = docopt.docopt(__doc__)
+ #print(args); raise SystemExit(0)
+
+ if args['install']:
+ install.install(args['<GAME_ID>'])
+ elif args['remove']:
+ remove.remove(args['<GAME_ID>'])
+ elif args['run']:
+ run.run(args['<GAME_ID>'], args['--profile_id'])
+
+
+if __name__ == "__main__":
+ main()