macos support

This commit is contained in:
Joey Eamigh
2023-06-22 13:39:56 -04:00
parent 93409a83f8
commit a38910cbaf
3 changed files with 27 additions and 19 deletions

View File

@@ -16,8 +16,9 @@ MULTIMC_DIR = ""
INSTANCE_DIR = ""
if OS == "darwin":
cprint("no support for macos yet", "red")
exit(1)
MULTIMC_PARENT_DIR = "/Applications/MultiMC.app"
MULTIMC_DIR = f"{MULTIMC_PARENT_DIR}/Data"
INSTANCE_DIR = f"{MULTIMC_DIR}/instances/FishPogPixelmon"
if OS == "linux":
MULTIMC_PARENT_DIR = f"{os.getenv('HOME')}/.local/share"
@@ -51,6 +52,9 @@ def run_mmc():
if OS == "linux":
subprocess.Popen(["./MultiMC"], stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL)
if OS == "darwin":
subprocess.Popen(["open", "-a", "MultiMC"], stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL)
# mods
def mods():