Skip to content

Commit

Permalink
support GE-Proton runners
Browse files Browse the repository at this point in the history
  • Loading branch information
mirkobrombin committed Mar 7, 2022
1 parent c5c5619 commit b22c1f8
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions src/backend/wine/winecommand.py
Original file line number Diff line number Diff line change
Expand Up @@ -276,28 +276,31 @@ def __get_runner(self) -> str:
if runner in [None, ""]:
return ""

if "Proton" in runner and "lutris" not in runner and config.get("Environment", "Custom") != "Steam":
if "Proton" in runner and config.get("Environment", "") != "Steam":
'''
If the runner is Proton, set the pat to /dist or /files
based on check if files exists.
'''
_runner = f"{runner}/files"
if os.path.exists(f"{Paths.runners}/{runner}/dist"):
_runner = f"{runner}/dist"
runner = _runner
elif config.get("Environment", "Custom") == "Steam":
runner = f"{Paths.runners}/{_runner}/bin/wine"

elif config.get("Environment", "") == "Steam":
'''
If the environment is Steam, runner path is defined
in the bottle configuration and point to the right
main folder.
'''
runner = f"{runner}/bin/wine"

elif runner.startswith("sys-"):
'''
If the runner type is system, set the runner binary
path to the system command. Else set it to the full path.
'''
runner = "wine"

else:
runner = f"{Paths.runners}/{runner}/bin/wine"

Expand Down

0 comments on commit b22c1f8

Please sign in to comment.