From 61df0838639e63b3e1ac020cebadbf66cf652405 Mon Sep 17 00:00:00 2001 From: clinton-hall Date: Thu, 21 Mar 2013 19:46:35 +1030 Subject: [PATCH] add windows builder files for nzbget --- .../windows-builder/README.md | 9 + .../windows-builder/autoProcessMedia.cfg | 105 ++++ .../windows-builder/logging.cfg | 23 + .../windows-builder/nzbget-postprocess.conf | 144 ++++++ .../windows-builder/nzbget-postprocess.py | 488 ++++++++++++++++++ 5 files changed, 769 insertions(+) create mode 100644 nzbget-postprocessing-files/windows-builder/README.md create mode 100644 nzbget-postprocessing-files/windows-builder/autoProcessMedia.cfg create mode 100644 nzbget-postprocessing-files/windows-builder/logging.cfg create mode 100644 nzbget-postprocessing-files/windows-builder/nzbget-postprocess.conf create mode 100644 nzbget-postprocessing-files/windows-builder/nzbget-postprocess.py diff --git a/nzbget-postprocessing-files/windows-builder/README.md b/nzbget-postprocessing-files/windows-builder/README.md new file mode 100644 index 00000000..ece7d9c1 --- /dev/null +++ b/nzbget-postprocessing-files/windows-builder/README.md @@ -0,0 +1,9 @@ +To compile for windows, add the following files into the same folder. +Compile with pyinstaller using options -F -w +Transcoder.py +Linktastic\linktastic.py folder (not used, but imported in nzbToMediaUtil.py) +nzbToMediaUtil.py +migratecfg.py +nzbToMediaEnv.py +nzbToMediaSceneExceptions.py +Autoprocess files \ No newline at end of file diff --git a/nzbget-postprocessing-files/windows-builder/autoProcessMedia.cfg b/nzbget-postprocessing-files/windows-builder/autoProcessMedia.cfg new file mode 100644 index 00000000..7f8ed985 --- /dev/null +++ b/nzbget-postprocessing-files/windows-builder/autoProcessMedia.cfg @@ -0,0 +1,105 @@ +[CouchPotato] +cpsCategory = movie +apikey = ac8a2260b147487c9c88a00fc9dde601 +host = localhost +port = 5050 +username = clinton +password = dlo3822 +ssl = 0 +web_root = +delay = 65 +method = renamer +delete_failed = 0 + +[SickBeard] +sbCategory = TV +host = localhost +port = 8081 +username = +password = +web_root = +ssl = 0 +watch_dir = C:\TV\new +failed_fork = 0 + +[HeadPhones] +hpCategory = music +apikey = +host = localhost +port = 8181 +username = +password = +ssl = 0 +web_root = +delay = 65 + +[Mylar] +mlCategory = comics +host = localhost +port = 8090 +username = +password = +web_root = +ssl = 0 + +[Gamez] +gzCategory = movie +apikey = +host = localhost +port = 8085 +username = +password = +ssl = 0 +web_root = + +[Torrent] +clientAgent = utorrent +useLink = 1 +minSampleSize = 200 +outputDirectory = C:\TV +categories = music_videos,pictures,software +uTorrentWEBui = http://localhost:8090/gui/ +uTorrentUSR = your username +uTorrentPWD = your password +deleteOriginal = 0 + +[Extensions] +compressedExtensions = .zip,.rar,.7z,.gz,.bz,.tar,.arj +mediaExtensions = .mkv,.avi,.divx,.xvid,.mov,.wmv,.mp4,.mpg,.mpeg,.vob,.iso +metaExtensions = .nfo,.sub,.srt,.jpg,.gif + +[Transcoder] +transcode = 0 +duplicate = 1 +ignoreExtensions = .avi +outputVideoExtension = .mp4 +outputVideoCodec = libx264 +outputVideoFramerate = 24 +outputVideoBitrate = 800k +outputAudioCodec = libmp3lame +outputAudioBitrate = 128k + +[loggers] +keys = root + +[handlers] +keys = console + +[formatters] +keys = generic + +[logger_root] +level = NOTSET +handlers = console +qualname = + +[handler_console] +class = StreamHandler +args = (sys.stdout,) +level = INFO +formatter = generic + +[formatter_generic] +format = %(asctime)s|%(levelname)-7.7s %(message)s +datefmt = %H:%M:%S + diff --git a/nzbget-postprocessing-files/windows-builder/logging.cfg b/nzbget-postprocessing-files/windows-builder/logging.cfg new file mode 100644 index 00000000..8855a44f --- /dev/null +++ b/nzbget-postprocessing-files/windows-builder/logging.cfg @@ -0,0 +1,23 @@ +# Logging configuration +[loggers] +keys = root + +[handlers] +keys = console + +[formatters] +keys = generic + +[logger_root] +level = NOTSET +handlers = console +qualname = + +[handler_console] +class = StreamHandler +args = (sys.stdout,) +level = INFO +formatter = generic + +[formatter_generic] +format = [%(levelname)-7.7s] %(message)s diff --git a/nzbget-postprocessing-files/windows-builder/nzbget-postprocess.conf b/nzbget-postprocessing-files/windows-builder/nzbget-postprocess.conf new file mode 100644 index 00000000..b0927a32 --- /dev/null +++ b/nzbget-postprocessing-files/windows-builder/nzbget-postprocess.conf @@ -0,0 +1,144 @@ +# +# This file if part of nzbget +# +# Template configuration file for post-processing script "nzbget-postprocess.sh". +# Please refer to "nzbget-postprocess.sh" for usage instructions. +# +# Copyright (C) 2008-2013 Andrey Prygunkov +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. +# +# + +############################################################################## +### PATHS ### + +# Set the full path to location to move failed downloads to. +Failed_Directory=/usr/local/downloads/failed + +############################################################################## +### OPTIONS ### + +# Rename img-files to iso (yes, no). +RenameIMG=yes + +# Joint TS-files (yes, no). +JoinTS=yes + +# Perform SickBeard's postprocessing (yes, no). +SickBeard=yes + +# Category for SickBeard's postprocessing. +SickBeardCategory=tv + +# Perform Couchpotato's postprocessing (yes, no). +CouchPotato=yes + +# Category for Couchpotato's postprocessing. +CouchPotatoCategory=movies + +# Perform HeadPhones' postprocessing (yes, no). +HeadPhones=yes + +# Category for HeadPhones' postprocessing. +HeadPhonesCategory=music + +# Perform Mylar's postprocessing (yes, no). +Mylar=yes + +# Category for Mylar's postprocessing. +MylarCategory=comics + +# Perform Gamez's postprocessing (yes, no). +Gamez=yes + +# Category for Gamez's postprocessing. +GamezCategory=games + +# Clean up list. space seperated, in single quotes, default '.nzb .sfv .1' +FileCleanUp='.nzb .sfv .1' + +# Remove all files when download fails (yes, no). +Delete_Failed=no + +# Toggle detailed output (yes, no). +Debug=no + +############################################################################## +### POSTPROCESSING-PARAMETERS ### + +# This section defines parameters, which can be set for each nzb-file +# individually using either web-interface or command line. +# Example command line for setting parameter "PostProcess" to value "no" for +# nzb-file with id=2: +# nzbget -E G O PostProcess=no 2 + +# Perform postprocessing (yes, no). +# +# Set to "no" to skip postprocessing for this nzb-file. +PostProcess=yes + +# Destination directory. +DestDir= + +############################################################################## +### EMAIL-PARAMETERS ### + +# This section defines parameters, which can be set to allow notifications to +# be sent via email. +# This uses sendEmail as authored by Brandon Zehm + +# List Categories for successful download email, default 'tv movies' +Email_successful='tv movies music comics games pictures' + +# List Categories for failed download email, default 'tv movies' +Email_failed='tv movies music comics games pictures' + +# Set the full path and file name for sendEmail application. +sendEmail=/usr/local/nzbget/var/sendEmail/sendEmail + +# Enter the email address you want this email to be sent from. +Email_From= + +# Enter the email address you want this email to be sent to. +Email_To= + +# Enter smtp server and port. eg smtp.live.com:25 +Email_Server= + +# Server uses tsl (auto, yes, no). +Tsl=auto + +# Enter your smtp server user name (if required) +Email_User= + +# Enter your smtp server password (if required) +Email_Pass= + +# Enter your email subject, in single quotes. +# Use the following tags between the less than and greater than symbols. +# Use status to add 'completed'/'failed'. +# Use name to add the nzb name. +# Use cat to add the download categoty. +# Use script to name the external script used. +Email_Subject='The download of has .' + +# Enter your email message, in single quotes. +# Use the same substitutes as described above. +# Use \r\n for new line. +Email_Message='The download of has . \r\n This has been processed by the script