diff --git a/Whisky/Utils/Winetricks.swift b/Whisky/Utils/Winetricks.swift index 5308ac5b..bd0b1478 100644 --- a/Whisky/Utils/Winetricks.swift +++ b/Whisky/Utils/Winetricks.swift @@ -46,8 +46,9 @@ class Winetricks { .appending(path: "winetricks") static func runCommand(command: String, bottle: Bottle) async { + guard let cabextractURL = Bundle.main.url(forResource: "cabextract", withExtension: nil) else { return } // swiftlint:disable:next line_length - let winetricksCmd = #"PATH=\"\#(GPTKInstaller.binFolder.path):$PATH\" WINE=wine64 WINEPREFIX=\"\#(bottle.url.path)\" \"\#(winetricksURL.path(percentEncoded: false))\" \#(command)"# + let winetricksCmd = #"PATH=\"\#(GPTKInstaller.binFolder.path):\#(cabextractURL.path(percentEncoded: false)):$PATH\" WINE=wine64 WINEPREFIX=\"\#(bottle.url.path)\" \"\#(winetricksURL.path(percentEncoded: false))\" \#(command)"# let script = """ tell application "Terminal"