From c3024ba396a9e3d083cc8890d33b3b6658387655 Mon Sep 17 00:00:00 2001 From: flan Date: Mon, 20 Aug 2018 14:42:40 +0200 Subject: [PATCH] Make the server runnable with python3 -m ankisyncd --- ankisyncd/__main__.py | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 ankisyncd/__main__.py diff --git a/ankisyncd/__main__.py b/ankisyncd/__main__.py new file mode 100644 index 0000000..c6a4f13 --- /dev/null +++ b/ankisyncd/__main__.py @@ -0,0 +1,11 @@ +import sys + +if __package__ is None and not hasattr(sys, "frozen"): + import os.path + path = os.path.realpath(os.path.abspath(__file__)) + sys.path.insert(0, os.path.dirname(os.path.dirname(path))) + +import ankisyncd.sync_app + +if __name__ == "__main__": + ankisyncd.sync_app.main()