support pyinstaller

This commit is contained in:
ed 2021-05-12 21:21:07 +02:00
parent c7d9cbb11f
commit 403261a293

View file

@ -24,6 +24,9 @@ MACOS = platform.system() == "Darwin"
class EnvParams(object):
def __init__(self):
self.mod = os.path.dirname(os.path.realpath(__file__))
if self.mod.endswith("__init__"):
self.mod = os.path.dirname(self.mod)
if sys.platform == "win32":
self.cfg = os.path.normpath(os.environ["APPDATA"] + "/copyparty")
elif sys.platform == "darwin":