mirror of
https://github.com/clinton-hall/nzbToMedia.git
synced 2025-07-16 02:02:53 -07:00
check is chp.exe exists. fixes #99
This commit is contained in:
parent
34357280be
commit
a5be594abe
1 changed files with 4 additions and 1 deletions
|
@ -54,7 +54,10 @@ def extract(filePath, outputDestination):
|
||||||
Logger.error("EXTRACTOR: Could not find 7-zip, Exiting")
|
Logger.error("EXTRACTOR: Could not find 7-zip, Exiting")
|
||||||
sys.exit(-1)
|
sys.exit(-1)
|
||||||
else:
|
else:
|
||||||
cmd_7zip = [chplocation, sevenzipLocation, "x", "-y"]
|
if not os.path.exists(chplocation):
|
||||||
|
cmd_7zip = [sevenzipLocation, "x", "-y"]
|
||||||
|
else:
|
||||||
|
cmd_7zip = [chplocation, sevenzipLocation, "x", "-y"]
|
||||||
ext_7zip = [".rar",".zip",".tar.gz","tgz",".tar.bz2",".tbz",".tar.lzma",".tlz",".7z",".xz"]
|
ext_7zip = [".rar",".zip",".tar.gz","tgz",".tar.bz2",".tbz",".tar.lzma",".tlz",".7z",".xz"]
|
||||||
EXTRACT_COMMANDS = dict.fromkeys(ext_7zip, cmd_7zip)
|
EXTRACT_COMMANDS = dict.fromkeys(ext_7zip, cmd_7zip)
|
||||||
# Using unix
|
# Using unix
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue