Added NZB_CLIENTAGENT and TORRENT_CLIENTAGENT variables to compliment adding in Nzb client API support for SabNZBD and NzbGet.

Partially added in searching for downloads via download client API calls, more work to be done on this.

NZB Client users but set there client in the cfg, either sabnzbd or nzbget.

Cleaned up some more of the code in TorrentToMedia and nzbToMedia.
This commit is contained in:
echel0n 2014-04-17 18:05:01 -07:00
commit 504ea8ac45
7 changed files with 160 additions and 139 deletions

View file

@ -2,7 +2,7 @@ import os
import sys
import nzbtomedia
from subprocess import call, Popen
from nzbtomedia.nzbToMediaUtil import create_destination
from nzbtomedia.nzbToMediaUtil import makeDir
from nzbtomedia import logger
# which() and os_platform() breaks when running in Transmission (has to do with os.environ)
@ -91,7 +91,7 @@ def extract(filePath, outputDestination):
return False
# Create outputDestination folder
create_destination(outputDestination)
makeDir(outputDestination)
passwordsfile = nzbtomedia.CFG["passwords"]["PassWordFile"]
if passwordsfile != "" and os.path.isfile(os.path.normpath(passwordsfile)):