Set itch Windows location
This commit is contained in:
@@ -44,7 +44,7 @@ def heroic_parser(parent_widget):
|
|||||||
)
|
)
|
||||||
elif os.name == "nt" and (Path(os.getenv("appdata")) / "heroic").exists():
|
elif os.name == "nt" and (Path(os.getenv("appdata")) / "heroic").exists():
|
||||||
schema.set_string(
|
schema.set_string(
|
||||||
"heroic-location", str(Path(os.getenv("appdata") / "heroic"))
|
"heroic-location", str(Path(os.getenv("appdata")) / "heroic")
|
||||||
)
|
)
|
||||||
else:
|
else:
|
||||||
return
|
return
|
||||||
|
|||||||
@@ -17,6 +17,7 @@
|
|||||||
#
|
#
|
||||||
# SPDX-License-Identifier: GPL-3.0-or-later
|
# SPDX-License-Identifier: GPL-3.0-or-later
|
||||||
|
|
||||||
|
import os
|
||||||
import urllib.request
|
import urllib.request
|
||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
from shutil import copyfile
|
from shutil import copyfile
|
||||||
@@ -120,6 +121,8 @@ def itch_parser(parent_widget):
|
|||||||
schema.set_string("itch-location", "~/.var/app/io.itch.itch/config/itch/")
|
schema.set_string("itch-location", "~/.var/app/io.itch.itch/config/itch/")
|
||||||
elif (parent_widget.config_dir / "itch").exists():
|
elif (parent_widget.config_dir / "itch").exists():
|
||||||
schema.set_string("itch-location", str(parent_widget.config_dir / "itch"))
|
schema.set_string("itch-location", str(parent_widget.config_dir / "itch"))
|
||||||
|
elif os.name == "nt" and (Path(os.getenv("appdata")) / "itch").exists():
|
||||||
|
schema.set_string("itch-location", str(Path(os.getenv("appdata")) / "itch"))
|
||||||
else:
|
else:
|
||||||
return
|
return
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user