From: Eli Schwartz Date: Sun, 22 Mar 2015 06:36:15 +0000 (-0500) Subject: Linux: Allow using ~ when specifying a wineprefix. X-Git-Url: http://git.xmof.duckdns.org/?a=commitdiff_plain;h=f2190a67558a;p=DeDRM.git Linux: Allow using ~ when specifying a wineprefix. --- diff --git a/DeDRM_calibre_plugin/DeDRM_plugin/wineutils.py b/DeDRM_calibre_plugin/DeDRM_plugin/wineutils.py index b54db80..6d79c9b 100644 --- a/DeDRM_calibre_plugin/DeDRM_plugin/wineutils.py +++ b/DeDRM_calibre_plugin/DeDRM_plugin/wineutils.py @@ -26,6 +26,7 @@ def WineGetKeys(scriptpath, extension, wineprefix=""): if not os.path.exists(outdirpath): os.makedirs(outdirpath) + wineprefix = os.path.abspath(os.path.expanduser(os.path.expandvars(wineprefix))) if wineprefix != "" and os.path.exists(wineprefix): cmdline = u"WINEPREFIX=\"{2}\" wine python.exe \"{0}\" \"{1}\"".format(scriptpath,outdirpath,wineprefix) else: