add 7za as alias for 7z and 7zr.

This commit is contained in:
clinton-hall 2014-11-01 08:30:49 +10:30
commit 9b143cd6f2
2 changed files with 6 additions and 0 deletions

View file

@ -47,6 +47,8 @@ def extract(filePath, outputDestination):
if call(['which', cmd], stdout=devnull, stderr=devnull): #note, returns 0 if exists, or 1 if doesn't exist.
if cmd == "7zr" and not call(["which", "7z"]): # we do have "7z" command
EXTRACT_COMMANDS[".7z"] = ["7z", "x"]
elif cmd == "7zr" and not call(["which", "7za"]): # we do have "7za" command
EXTRACT_COMMANDS[".7z"] = ["7za", "x"]
else:
for k, v in EXTRACT_COMMANDS.items():
if cmd in v[0]: