Advertisement
Guest User

Untitled

a guest
Mar 30th, 2017
151
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 33.46 KB | None | 0 0
  1.  
  2. This is an auto downloader for Irssi.
  3.  
  4. Features:
  5. [*] ruTorrent plugin (optional).
  6. [*] Supports your favorite tracker
  7. [*] Advanced but easy to use filters. No complicated regex required, not even wildcards for TV shows and movies.
  8. [*] Some of the filters: release, size, tracker, resolution, source (eg. BluRay), category, format (eg. FLAC), bitrate, and many more.
  9. [*] Torrent can be saved to a watch directory, or uploaded to uTorrent webui or an FTP server.
  10. [*] Option to set max downloads per day/week/month
  11. [*] Torrent data folder name can use info from the torrent or current date (eg. "dated" folders)
  12. [*] No broken .torrent files are ever uploaded to your client. Torrent files are verified before uploading them.
  13. [*] Duplicate releases are not downloaded by default.
  14. [*] Torrents are downloaded in the background so Irssi isn't blocked.
  15. [*] SSL downloads can be forced.
  16. [*] Automatic updates.
  17. [*] Automatically connects to IRC servers and channels
  18. [*] Wake on LAN
  19.  
  20. It can be downloaded here: http://sourceforge.net/projects/autodl-irssi/
  21.  
  22. [URL=http://img38.imageshack.us/i/filters1.png/][IMG]http://img38.imageshack.us/img38/3294/filters1.png[/IMG][/URL]
  23. [URL=http://img197.imageshack.us/i/filters2e.png/][IMG]http://img197.imageshack.us/img197/1296/filters2e.png[/IMG][/URL]
  24. [URL=http://img163.imageshack.us/i/filters3.png/][IMG]http://img163.imageshack.us/img163/9039/filters3.png[/IMG][/URL]
  25. [URL=http://img535.imageshack.us/i/prefs1.png/][IMG]http://img535.imageshack.us/img535/6194/prefs1.png[/IMG][/URL]
  26. [URL=http://img39.imageshack.us/i/servers1.png/][IMG]http://img39.imageshack.us/img39/153/servers1.png[/IMG][/URL]
  27.  
  28.  
  29.  
  30.  
  31. [b]Installation[/b]
  32.  
  33. The install script will install autodl-irssi and optionally also ruTorrent, the ruTorrent plugin and any other dependencies required to have a fully working ruTorrent install. It will ask a few questions and then install whatever you selected.
  34.  
  35. [b]Ubuntu and Ubuntu clones[/b]:
  36. [code]
  37. cd
  38. wget --no-check-certificate -O autodl-setup http://sourceforge.net/projects/autodl-irssi/files/autodl-setup/download
  39. sudo sh autodl-setup
  40. [/code]
  41.  
  42. [b]Any other OS[/b]
  43. Log in as root:
  44. [code]su -[/code]
  45. Then install it:
  46. [code]
  47. wget --no-check-certificate -O autodl-setup http://sourceforge.net/projects/autodl-irssi/files/autodl-setup/download
  48. sh autodl-setup
  49. [/code]
  50.  
  51.  
  52. To use the autodl-irssi ruTorrent plugin, click its icon at the top of ruTorrent. It's usually the icon to the left of ruTorrent's settings icon. The icon is either a white bubble or a white down arrow inside a green square. The autodl-irssi tab will show all autodl-irssi output as long as ruTorrent is loaded.
  53.  
  54.  
  55.  
  56. If you don't use the ruTorrent plugin, then you may want to send all autodl-irssi output to its own window:
  57. By default, all autodl-irssi output goes to the [b](status)[/b] window. If there's a window called [b]autodl[/b], then it will write all output to that window. Use these Irssi commands to create a new window named [b]autodl[/b] and place it right after the status window (i.e., window position 2):
  58. [code]First start Irssi! :D
  59. /window new hidden
  60. /window name autodl
  61. /window move 2
  62. /layout save
  63. /save[/code]
  64.  
  65.  
  66. Since some people don't want users to have shell access, it's also possible to disable the "exec" action. Create [b]/etc/autodl.cfg[/b] and add this:
  67.  
  68. [code]
  69. [options]
  70. allowed = watchdir, rtorrent
  71. [/code]
  72.  
  73. That will only enable the rtorrent and "Save to watch dir" actions. The following can be used with the [b]allowed[/b] option:
  74.  
  75. rtorrent
  76. watchdir
  77. webui (requires uTorrent)
  78. ftp
  79. exec
  80. dyndir (requires uTorrent)
  81.  
  82. It's a comma seperated list, eg.: allowed = watchdir, ftp
  83.  
  84.  
  85.  
  86. [b]Manual installation[/b]
  87.  
  88. If you can't use the installer for some reason, then try a manual install.
  89.  
  90. autodl-irssi requires Irssi compiled with Perl support.
  91.  
  92. autodl-irssi has the following Perl module dependencies:
  93. * Archive::Zip
  94. * Net::SSLeay
  95. * HTML::Entities
  96. * XML::LibXML
  97. * Digest::SHA1
  98. * JSON
  99. * JSON::XS (optional)
  100.  
  101. Use your package manager to install them or use the CPAN utility. If you use CPAN, you will need a build environment already installed, eg. gcc, make, etc.
  102.  
  103. [code]
  104. cpan Archive::Zip Net::SSLeay HTML::Entities XML::LibXML Digest::SHA1 JSON JSON::XS
  105. [/code]
  106.  
  107. The optional ruTorrent plugin has the following PHP dependencies:
  108. * json
  109. * sockets
  110. * xml
  111.  
  112. You can test for the presence of those modules by executing the following command. If you get no output then they're installed:
  113.  
  114. [code]for module in json xml sockets; do php -m|grep -wq $module || echo "Missing module: $module"; done[/code]
  115.  
  116. Use your package manager to install them unless they're already installed. You may need to edit your php.ini file by adding this:
  117.  
  118. [code]
  119. extension=sockets.so
  120. extension=json.so
  121. extension=xml.so
  122. [/code]
  123.  
  124. Don't forget to restart your web server if you make any changes to php.ini.
  125.  
  126.  
  127. Installing autodl-irssi. Note: Make sure you're [b]not[/b] root when you execute the following commands.
  128. [code]
  129. mkdir -p ~/.irssi/scripts/autorun
  130. cd ~/.irssi/scripts
  131. wget -O autodl-irssi.zip http://sourceforge.net/projects/autodl-irssi/files/autodl-irssi-v1.31.zip/download
  132. unzip -o autodl-irssi.zip
  133. rm autodl-irssi.zip
  134. cp autodl-irssi.pl autorun/
  135. mkdir -p ~/.autodl
  136. touch ~/.autodl/autodl.cfg
  137. [/code]
  138.  
  139. The autodl-irssi startup script has been copied to the autorun directory so it will be started automatically when Irssi is started.
  140.  
  141.  
  142. Installing the optional ruTorrent plugin. You may need to slightly modify the steps if you're not using Ubuntu or if ruTorrent isn't installed to /var/www/rutorrent/
  143.  
  144. [code]
  145. cd /var/www/rutorrent/plugins
  146. sudo svn co https://autodl-irssi.svn.sourceforge.net/svnroot/autodl-irssi/trunk/rutorrent/autodl-irssi
  147. sudo cp autodl-irssi/_conf.php autodl-irssi/conf.php
  148. sudo chown -R www-data:www-data autodl-irssi
  149. [/code]
  150.  
  151. This install assumes ruTorrent is not password protected. For password protected (i.e., multi-user) setup, you need to copy conf.php to the user plugins directory and not to the plugin directory. Eg. you need to copy it to a path similar to /var/www/rutorrent/conf/users/YOUR-USER-NAME/plugins/autodl-irssi
  152.  
  153. Edit conf.php with a text editor and add your port number and password. The port number should be a random number between 1024 and 65535 inclusive. The file should look something like this afterwards:
  154.  
  155. [code]
  156. <?php
  157. $autodlPort = 12345;
  158. $autodlPassword = "secretpass";
  159. ?>
  160. [/code]
  161.  
  162. Open ~/.autodl/autodl2.cfg with a text editor and add this to the file:
  163. [code]
  164. [options]
  165. gui-server-port = 12345
  166. gui-server-password = secretpass
  167. [/code]
  168.  
  169. If you start more than one Irssi process, make sure each Irssi process uses a unique port number! It won't work if they all use the same port number.
  170.  
  171.  
  172. [b]The autodl.cfg file[/b]
  173.  
  174. NOTE: If you're using the ruTorrent plugin, you don't need to read this! :D
  175.  
  176. All filters and other options are read from ~/.autodl/autodl.cfg. If you use non-ASCII characters, be sure to set the encoding (or character coding) to UTF-8 before saving it. The file will be automatically re-read whenever you make any modifications to it when autodl-irssi is running.
  177.  
  178. If you have used the ChatZilla auto downloader, I wrote a program that will convert autodl-cz's options into a format understood by autodl-irssi. See [b]Using autodl-cz's options[/b] somewhere near the bottom.
  179.  
  180. Here's an example autodl.cfg file you can modify:
  181. [quote]
  182. # Lines beginning with a '#' character are ignored (i.e., they're comments!)
  183.  
  184. # TV-shows/movies template: (note that wildcards aren't necessary in the [b]shows[/b] filter option!)
  185. [filter TV SHOW MOVIE FILTER TEMPLATE]
  186. shows = The Simpsons, Other show, 3rd Show, Some movie, Movie #2
  187. max-size = 2GB
  188. #seasons = 3-8
  189. #episodes = 0-99
  190. resolutions = SD, 720p
  191. sources = HDTV, DVDRip, BluRay
  192. encoders = xvid, x264
  193. #years = 2008-2012, 1950
  194. #match-sites =
  195.  
  196. # Music template:
  197. [filter MUSIC FILTER TEMPLATE]
  198. match-sites = what, waffles
  199. min-size = 30MB
  200. max-size = 1GB
  201. years = 1950-1969, 2000, 2009-2099
  202. #shows = ArtistOrGroup #1, ArtistOrGroup #2, etc
  203. #albums = Album #1, Album #2, etc
  204. formats = MP3, FLAC
  205. bitrates = v0 (vbr), lossless
  206. media = CD
  207. #tags = hip hop, tag #2, tag #3
  208. #tags-any = true
  209. #except-tags = hip hop, tag #2, tag #3
  210. #except-tags-any = false
  211. #scene =
  212. #log =
  213. #cue =
  214.  
  215. # Random scene releases:
  216. [filter RANDOM SCENE RELEASE FILTER TEMPLATE]
  217. match-releases = the?simpsons*, american?dad*, blah*
  218. except-releases = *-LOL, *-crapgroup, crap.release*
  219. #match-sites =
  220. #except-sites =
  221. #min-size = 10MB
  222. max-size = 500MB
  223. #max-pretime = 3 secs
  224. #match-uploaders =
  225. #except-uploaders =
  226.  
  227. # All releases from a certain category:
  228. [filter CATEGORY FILTER TEMPLATE]
  229. match-categories = *MP3*, *XVID*
  230. #except-categories = *XXX*
  231. #match-releases =
  232. #except-releases =
  233. #match-sites =
  234. #except-sites =
  235. #min-size =
  236. max-size = 10GB
  237.  
  238. [filter rtorrent stuff]
  239. match-releases = Some.Random.Release-GRP
  240. # ... etc
  241. upload-type = rtorrent
  242. rt-dir = /home/YOURNAME/downloads/$(Month)$(Day)/$(Tracker)
  243. #rt-commands = print="Added: $(TorrentName)"; print="Hello, world!"
  244. rt-label = $(Tracker)
  245. #rt-ratio-group = rat_3
  246. #rt-channel = thr_2
  247. rt-priority = high
  248. #rt-ignore-scheduler = true
  249. #rt-dont-add-name = false
  250.  
  251. [options]
  252. max-saved-releases = 1000
  253. save-download-history = true
  254. download-duplicates = false
  255. upload-type = watchdir
  256. #upload-type = webui
  257. #upload-type = ftp
  258. upload-watch-dir = /home/username/watchdir
  259. upload-ftp-path = /
  260.  
  261. [webui]
  262. user =
  263. password =
  264. hostname =
  265. port =
  266. ssl =
  267.  
  268. [ftp]
  269. user =
  270. password =
  271. hostname =
  272. port =
  273.  
  274. [tracker scc]
  275. authkey =
  276. [/quote]
  277.  
  278. All lines starting with the # character are ignored (they're comments). Use it to disable some options.
  279.  
  280. The file contains several headers of the form [b][headername][/b] and header options immediately below the header. The options are of the form [b]option-name = option-value[/b]. If you leave out the value or option-name, then the default value will be used.
  281.  
  282. There are a few different option types:
  283. Comma separated list. eg. [b]value1, value2, value3[/b].
  284. List of numbers. eg. [b]1980-1999, 2010, 2012[/b]
  285. String. Any number of random characters.
  286. Integer. Any integer.
  287. Boolean. [b]false[/b], [b]off[/b], [b]no[/b], or [b]0[/b] all mean "false". Anything else means "true".
  288. Size. eg. [b]120 MB[/b] or [b]4.5GB[/b]
  289.  
  290. All option values are case-insensitive so eg. [b]The Simpsons[/b] is the same thing as [b]the siMPSonS[/b].
  291.  
  292. The comma separated list type supports wildcards, where the [b]*[/b] character means 0 or more characters, and the [b]?[/b] character means exactly one character. Google wildcards for more information. Example, [b]*simpsons*[/b] will match any text with the word simpsons in it. It means [b]First 0 or more characters, then "simpsons", then 0 or more characters[/b]. Note that [b]simpsons*[/b] is not the same thing, it means [b]First "simpsons" then 0 or more characters[/b], so [b]simpsons*[/b] will match anything that begins with the word "simpsons" followed by any text.
  293.  
  294. [b]The filter header[/b]
  295. Create one [filter] header per filter. You can optionally name the filter like [b][filter MY FILTER NAME][/b]. All filter options are optional! If you don't use any filter options, then everything will be downloaded because your filter doesn't filter out anything.
  296.  
  297. [b]Name:[/b] enabled
  298. [b]Type:[/b] Boolean
  299. [b]Default:[/b] true
  300. [b]Example:[/b] enabled = false
  301. [b]Description:[/b] Use it to disable a filter. All filters are enabled by default.
  302.  
  303. [b]Name:[/b] match-releases
  304. [b]Type:[/b] Comma separated list
  305. [b]Example:[/b] match-releases = The?Simpsons*, American?Dad*
  306. [b]Description:[/b] It's compared against the torrent name, eg. [b]Some.release.720p.HDTV-GROUP[/b]. If the filter should only match TV-shows or movies, it's easier to use the [b]shows[/b] filter option since it doesn't require wildcards.
  307.  
  308. [b]Name:[/b] except-releases
  309. [b]Description:[/b] The exact opposite of [b]match-releases[/b]. If a release matches this option, then it's NOT downloaded.
  310.  
  311. [b]Name:[/b] match-categories
  312. [b]Type:[/b] Comma separated list
  313. [b]Example:[/b] match-categories = *MP3*, TV/XVID
  314. [b]Description:[/b] It's compared against the torrent category.
  315.  
  316. [b]Name:[/b] except-categories
  317. [b]Description:[/b] The exact opposite of [b]except-categories[/b]. If a release matches this option, then it's NOT downloaded.
  318.  
  319. [b]Name:[/b] match-sites
  320. [b]Type:[/b] Comma separated list
  321. [b]Example:[/b] match-sites = tracker1, tracker2, tracker3
  322. [b]Description:[/b] It's compared against the tracker. Use the full tracker name, eg. MyTracker or use one of the tracker types found in ~/.irssi/scripts/AutodlIrssi/trackers/*.tracker. Open one of the files and locate the [b]type="XYZ"[/b] line. Use the value inside the quotes, eg. [b]XYZ[/b].
  323.  
  324. [b]Name:[/b] except-sites
  325. [b]Description:[/b] The exact opposite of [b]match-sites[/b]. If a release matches this option, then it's NOT downloaded.
  326.  
  327. [b]Name:[/b] min-size
  328. [b]Type:[/b] Size
  329. [b]Example:[/b] min-size = 200MB
  330. [b]Default:[/b] 0
  331. [b]Description:[/b] Used to filter out too small torrents.
  332.  
  333. [b]Name:[/b] max-size
  334. [b]Type:[/b] Size
  335. [b]Example:[/b] max-size = 2.5GB
  336. [b]Default:[/b] any size is allowed
  337. [b]Description:[/b] Used to filter out too big torrents. I recommend everyone to always use this option so you don't accidentally download a 100GB torrent! :D Set it to a reasonable value, eg. for TV-shows, set it to about twice the size of a normal episode (just in case it's a double-episode). This will automatically filter out season packs!
  338.  
  339. [b]Name:[/b] shows
  340. [b]Type:[/b] Comma separated list
  341. [b]Example:[/b] shows = The Simpsons, American Dad
  342. [b]Description:[/b] This is for TV-shows, movies and artists/groups (what.cd/waffles only). autodl-irssi will automatically extract the TV-show/movie name from a scene release name. Example, The.Simpsons.S35E24.720p.HDTV-BLAH will match a [b]shows[/b] option set to [b]the simpsons[/b]. You don't need wildcards at all, though it's possible to use wildcards. It's recommended to use [b]shows[/b] instead of [b]match-releases[/b] if all you want is for the filter to match TV-shows or movies. what.cd and waffles: this will match against the artist/group.
  343.  
  344. [b]Name:[/b] seasons
  345. [b]Type:[/b] List of numbers
  346. [b]Example:[/b] seasons = 1, 3, 5-10
  347. [b]Description:[/b] This is for TV-shows only. Unless the release matches one of the seasons, it's not downloaded.
  348.  
  349. [b]Name:[/b] episodes
  350. [b]Type:[/b] List of numbers
  351. [b]Example:[/b] episodes = 1, 3, 5-10
  352. [b]Description:[/b] This is for TV-shows only. Unless the release matches one of the episodes, it's not downloaded.
  353.  
  354. [b]Name:[/b] resolutions
  355. [b]Type:[/b] Comma separated list
  356. [b]Example:[/b] resolutions = SD, 720p, 1080p
  357. [b]Description:[/b] This is for TV-shows and movies only. Unless the release matches one of the resolutions, it's not downloaded. Valid resolutions are one or more of the following: [b]SD[/b], [b]480i[/b], [b]480p[/b], [b]576p[/b], [b]720p[/b], [b]810p[/b], [b]1080i[/b], [b]1080p[/b].
  358.  
  359. [b]Name:[/b] sources
  360. [b]Type:[/b] Comma separated list
  361. [b]Example:[/b] sources = HDTV, DVDRip, BluRay
  362. [b]Description:[/b] This is for TV-shows and movies only. Unless the release matches one of the sources, it's not downloaded. Valid sources are one or more of the following: [b]DSR[/b], [b]PDTV[/b], [b]HDTV[/b], [b]HR.PDTV[/b], [b]HR.HDTV[/b], [b]DVDRip[/b], [b]DVDScr[/b], [b]BDr[/b], [b]BD5[/b], [b]BD9[/b], [b]BDRip[/b], [b]BRRip[/b], [b]DVDR[/b], [b]MDVDR[/b], [b]HDDVD[/b], [b]HDDVDRip[/b], [b]BluRay[/b], [b]WEB-DL[/b], [b]TVRip[/b], [b]CAM[/b], [b]R5[/b], [b]TELESYNC[/b], [b]TS[/b], [b]TELECINE[/b], [b]TC[/b]. [b]TELESYNC[/b] and [b]TS[/b] are synonyms (you don't need both). Same for [b]TELECINE[/b] and [b]TC[/b].
  363.  
  364. [b]Name:[/b] encoders
  365. [b]Type:[/b] Comma separated list
  366. [b]Example:[/b] encoders = x264, xvid
  367. [b]Description:[/b] If you don't want windows WMV files, this option could be useful. :) Valid encoders are: [b]XviD[/b], [b]DivX[/b], [b]x264[/b], [b]h.264[/b] (or [b]h264[/b]), [b]mpeg2[/b] (or [b]mpeg-2[/b]), [b]VC-1[/b] (or [b]VC1[/b]), [b]WMV[/b].
  368.  
  369. [b]Name:[/b] years
  370. [b]Type:[/b] List of numbers
  371. [b]Example:[/b] years = 1999, 2005-2010
  372. [b]Description:[/b] Not all releases have a year in the torrent name, but if it does, you can use it to filter out too old or too new releases.
  373.  
  374. [b]Name:[/b] albums
  375. [b]Type:[/b] Comma separated list
  376. [b]Example:[/b] albums = Some album, Some other album, yet another one
  377. [b]Description:[/b] what.cd/waffles only.
  378.  
  379. [b]Name:[/b] formats
  380. [b]Type:[/b] Comma separated list
  381. [b]Example:[/b] formats = MP3, FLAC
  382. [b]Description:[/b] what.cd/waffles only. List the formats you want. Valid formats are: [b]MP3[/b], [b]FLAC[/b], [b]Ogg[/b], [b]AAC[/b], [b]AC3[/b], [b]DTS[/b].
  383.  
  384. [b]Name:[/b] bitrates
  385. [b]Type:[/b] Comma separated list
  386. [b]Example:[/b] bitrates = 192, V0 (vbr), lossless
  387. [b]Description:[/b] what.cd/waffles only. List the bitrates you want. Some example values: [b]192[/b], [b]320[/b], [b]APS (VBR)[/b], [b]V2 (VBR)[/b], [b]V1 (VBR)[/b], [b]APX (VBR)[/b], [b]V0 (VBR)[/b], [b]q8.x (VBR)[/b], [b]Lossless[/b], [b]24bit Lossless[/b], [b]Other[/b].
  388.  
  389. [b]Name:[/b] media
  390. [b]Type:[/b] Comma separated list
  391. [b]Example:[/b] media = CD, WEB
  392. [b]Description:[/b] what.cd/waffles only. List the media you want. Valid media are: [b]CD[/b], [b]DVD[/b], [b]Vinyl[/b], [b]Soundboard[/b], [b]SACD[/b], [b]DAT[/b], [b]Cassette[/b], [b]WEB[/b], [b]Other[/b].
  393.  
  394. [b]Name:[/b] tags
  395. [b]Type:[/b] Comma separated list
  396. [b]Example:[/b] tags = hip hop, rock
  397. [b]Description:[/b] what.cd/waffles only. Unless at least one of your tags matches the release's tags, it's not downloaded. See also [b]except-tags[/b] and [b]tags-any[/b].
  398.  
  399. [b]Name:[/b] except-tags
  400. [b]Type:[/b] Comma separated list
  401. [b]Example:[/b] except-tags = hip hop, rock
  402. [b]Description:[/b] what.cd/waffles only. Same as [b]tags[/b] except if it matches any/all of these, it's not downloaded. See also [b]tags[/b] and [b]except-tags-any[/b].
  403.  
  404. [b]Name:[/b] tags-any
  405. [b]Type:[/b] Boolean
  406. [b]Default:[/b] true
  407. [b]Example:[/b] tags-any = false
  408. [b]Description:[/b] what.cd/waffles only. Decides how to match the [b]tags[/b] option, ie., if any or all of the tags must match.
  409.  
  410. [b]Name:[/b] except-tags-any
  411. [b]Type:[/b] Boolean
  412. [b]Default:[/b] true
  413. [b]Example:[/b] except-tags-any = true
  414. [b]Description:[/b] what.cd/waffles only. Decides how to match the [b]except-tags[/b] option, ie., if any or all of the tags must match.
  415.  
  416. [b]Name:[/b] scene
  417. [b]Type:[/b] Boolean
  418. [b]Example:[/b] scene = true
  419. [b]Description:[/b] what.cd/waffles, and a few others. Some sites mark a release as scene or non-scene. Set it to true if you want only scene releases, false if you only want non-scene releases, or don't use this option if you don't care.
  420.  
  421. [b]Name:[/b] log
  422. [b]Type:[/b] Boolean
  423. [b]Example:[/b] log = true
  424. [b]Description:[/b] what.cd/waffles. Set it to true if you only want releases with a log file, false if you don't want releases with log files, or don't use this option if you don't care.
  425.  
  426. [b]Name:[/b] cue
  427. [b]Type:[/b] Boolean
  428. [b]Example:[/b] cue = true
  429. [b]Description:[/b] what.cd. Set it to true if you only want releases with a cue file, false if you don't want releases with cue files, or don't use this option if you don't care.
  430.  
  431. [b]Name:[/b] match-uploaders
  432. [b]Type:[/b] Comma separated list
  433. [b]Example:[/b] match-uploaders = uploader1, uploader2
  434. [b]Description:[/b] Use it to only download from certain uploaders.
  435.  
  436. [b]Name:[/b] except-uploaders
  437. [b]Description:[/b] The exact opposite of [b]match-uploaders[/b]. If a release matches this option, then it's NOT downloaded.
  438.  
  439. [b]Name:[/b] max-pretime
  440. [b]Type:[/b] time-since string
  441. [b]Example:[/b] max-pretime = 2 mins 3 secs
  442. [b]Description:[/b] Some sites announce the pretime of the release. Use this to filter out old releases.
  443.  
  444. [b]Name:[/b] max-downloads
  445. [b]Type:[/b] Integer
  446. [b]Example:[/b] max-downloads = 15
  447. [b]Description:[/b] Download no more than this number of torrents per week/month (see [b]max-downloads-per[/b]). Remove the filter option or set it to a negative number to disable it.
  448.  
  449. [b]Name:[/b] max-downloads-per
  450. [b]Type:[/b] String
  451. [b]Example:[/b] max-downloads-per = week
  452. [b]Description:[/b] Valid values are [b]day[/b], [b]week[/b], and [b]month[/b]. See [b]max-downloads[/b].
  453.  
  454. [b]The options header[/b]
  455. These options change the behavior of autodl-irssi. Place these options below the [b][options][/b] header.
  456.  
  457. [b]Name:[/b] rt-address
  458. [b]Type:[/b] string
  459. [b]Default:[/b] Whatever is found in ~/.rtorrent.rc
  460. [b]Example:[/b] rt-address = 127.0.0.1:5000
  461. [b]Description:[/b] If you use the 'rtorrent' action ([b]upload-method[/b]), then you must initialize this to your rtorrent's SCGI address. It can be ip:port (eg. 127.0.0.1:5000) or /path/to/socket. [b]NOTE:[/b] This option can only be set in autodl2.cfg, [b]not[/b] autodl.cfg.
  462.  
  463.  
  464. [b]Name:[/b] update-check
  465. [b]Type:[/b] string
  466. [b]Default:[/b] ask
  467. [b]Example:[/b] update-check = auto
  468. [b]Description:[/b] autodl-irssi can auto update itself. Valid values are [b]ask[/b], [b]auto[/b], and [b]disabled[/b]. [b]ask[/b] will print a message when there's a new version. [b]auto[/b] will automatically update it when there's a new version. [b]disabled[/b] won't do a thing when there's a new update.
  469.  
  470. [b]Name:[/b] max-saved-releases
  471. [b]Type:[/b] Integer greater than or equal to 0.
  472. [b]Default:[/b] 1000
  473. [b]Example:[/b] max-saved-releases = 200
  474. [b]Description:[/b] autodl-irssi will remember the last [b]max-saved-releases[/b] releases you have downloaded so it won't re-download the same file again. Only useful if [b]save-download-history[/b] is enabled.
  475.  
  476. [b]Name:[/b] save-download-history
  477. [b]Type:[/b] Boolean
  478. [b]Default:[/b] true
  479. [b]Example:[/b] save-download-history = true
  480. [b]Description:[/b] Set it to false to disable writing the last N (= [b]max-saved-releases[/b]) downloaded releases to ~/.autodl/DownloadHistory.txt.
  481.  
  482. [b]Name:[/b] download-duplicates
  483. [b]Type:[/b] Boolean
  484. [b]Default:[/b] false
  485. [b]Example:[/b] download-duplicates = true
  486. [b]Description:[/b] By default, it's false so no duplicate releases are downloaded. Set it to true if you want to download the same release again if it's re-announced.
  487.  
  488. [b]Name:[/b] unique-torrent-names
  489. [b]Type:[/b] Boolean
  490. [b]Default:[/b] false
  491. [b]Example:[/b] unique-torrent-names = true
  492. [b]Description:[/b] If true, all saved torrent filenames are unique (the site name is prepended to the filename). Set it to false to use the torrent release name as the filename.
  493.  
  494. [b]Name:[/b] download-retry-time-seconds
  495. [b]Type:[/b] Integer
  496. [b]Default:[/b] 300
  497. [b]Example:[/b] download-retry-time-seconds = 120
  498. [b]Description:[/b] If a download fails, autodl-irssi will try to re-download it after waiting a little while. If it still can't download it after [b]download-retry-time-seconds[/b] seconds, it will give up and report an error.
  499.  
  500. [b]Name:[/b] path-utorrent
  501. [b]Type:[/b] String
  502. [b]Default:[/b] nothing
  503. [b]Example:[/b] path-utorrent = /cygdrive/c/Program Files (x86)/uTorrent/uTorrent.exe
  504. [b]Description:[/b] Set it to the path of uTorrent if you're using an [b]upload-type[/b] equal to [b]dyndir[/b].
  505.  
  506.  
  507. [b]Sending Wake on LAN (WOL)[/b]
  508. It's possible to wake up the computer before uploading the torrent (uTorrent webui or FTP upload). You may need to make sure your BIOS and network card have WOL enabled.
  509.  
  510. wol-mac-address = 00:11:22:33:44:55
  511. wol-ip-address = 12.34.56.78 (or a DNS name, eg. www.blah.com)
  512. wol-port = 9 (defaults to 9 if you leave it blank)
  513.  
  514. [b]wol-mac-address[/b] is the MAC (or hardware) address of the computer's network card. Use ifconfig /all (windows) or ifconfig -a (Linux) to find out your network card's MAC address.
  515.  
  516. If you have a router, then set [b]wol-ip-address[/b] to your router's public IP address, and make sure the router forwards UDP packets to port [b]wol-port[/b] (default 9) to your router's internal broadcast address (usually 192.168.0.255).
  517.  
  518.  
  519. [b]Torrent action options[/b]
  520. autodl-irssi can save a torrent file to a watch directory, upload it to uTorrent webui, upload it to an FTP server, execute a program or use uTorrent to save it to a dynamic directory name that depends on the current torrent.
  521.  
  522. There's a global action option in the [options] header and a local action option in each filter. By default, the global action option is used but you can override it in any filter by placing a new [b]upload-type[/b] below your [filter] header.
  523.  
  524. [b]rtorrent only:[/b]
  525. [quote]
  526. upload-type = rtorrent
  527. rt-dir = /home/YOURNAME/downloads/$(Month)$(Day)/$(Tracker)
  528. rt-commands = print="Added: $(TorrentName)"; print="Hello, world!"
  529. rt-label = $(Tracker)
  530. #rt-ratio-group = rat_3
  531. #rt-channel = thr_2
  532. rt-priority = high
  533. #rt-ignore-scheduler = true
  534. #rt-dont-add-name = false
  535. [/quote]
  536.  
  537. [b]rt-dir[/b] is the destination directory. The torrent data will be saved here. Macros can be used.
  538. [b]rt-commands[/b] can be used to execute some rtorrent commands when loading the torrent file. It's for advanced users only.
  539. [b]rt-label[/b] is used to set a ruTorrent label.
  540. [b]rt-ratio-group[/b] is used to set a ruTorrent ratio group. Valid names are rat_0, rat_1, ..., rat_7. You must have the ratio ruTorrent plugin installed.
  541. [b]rt-channel[/b] is used to set a ruTorrent channel. Valid names are thr_0, thr_1, ..., thr_9. You must have the throttle ruTorrent plugin installed.
  542. [b]rt-priority[/b] sets the torrent priority. Valid values are 0, dont-download, 1, low, 2, normal, 3, high. If you set it to dont-download (or 0), the torrent is loaded, but not started.
  543. [b]rt-ignore-scheduler[/b]: set it to true to disable the ruTorrent scheduler.
  544. [b]rt-dont-add-name[/b]: set it to true if you don't want the torrent name to be added to the path.
  545.  
  546.  
  547. [b]Save torrent to a watch directory:[/b]
  548. [quote]
  549. upload-type = watchdir
  550. upload-watch-dir = /home/myusername/mywatchdir
  551. [/quote]
  552.  
  553. [b]Upload torrent to uTorrent webui:[/b]
  554. Don't forget to initialize webui user, password, etc below the [webui] header!
  555. [quote]
  556. upload-type = webui
  557. [/quote]
  558.  
  559. [b]Upload torrent to an FTP server:[/b]
  560. Don't forget to initialize FTP user, password, etc below the [ftp] header!
  561. [quote]
  562. upload-type = ftp
  563. upload-ftp-path = /ftp/server/path
  564. [/quote]
  565.  
  566. [b]Execute a program:[/b]
  567. [quote]
  568. upload-type = exec
  569. upload-command = /path/to/program
  570. upload-args = all arguments here
  571. [/quote]
  572.  
  573. Both [b]upload-command[/b] and [b]upload-args[/b] support macros. See Macros below for an explanation of all available macros. Just remember to enclose the macro in double quotes if it's possible that the macro contains spaces. Example: [b]upload-args = --torrent "$(TorrentPathName)" --category $(Category)[/b]
  574.  
  575.  
  576. [b]Save torrent data to a dynamic directory using uTorrent:[/b]
  577. You need to initialize [b]path-utorrent[/b] below [options] or it won't work!
  578. [quote]
  579. upload-type = dyndir
  580. upload-dyndir = c:\the\windows\path\$(macro)$(macro2)\$(macro3)
  581. [/quote]
  582.  
  583. Important: autodl-irssi assumes that the Z: drive is mapped to your / (root) directory if you're using Wine to run uTorrent.
  584.  
  585. [b]upload-dyndir[/b] supports macros. See Macros below for an explanation of all available macros. You can use macros to create a directory based on current day and month. Some examples:
  586.  
  587. [b]upload-dyndir = c:\mydownloads\$(year)-$(month)-$(day)[/b] will save the torrent data below a directory containing the current year, month and day. Eg. [b]c:\mydownloads\2010-10-28[/b] if 2010-10-28 happened to be the current day.
  588.  
  589. [b]upload-dyndir = c:\mydownloads\$(month)$(day)\$(trackershort)\$(category)[/b] will save the data to a directory based on current month, day, tracker name, and torrent category.
  590.  
  591. [b]The webui header[/b]
  592. [quote]
  593. [webui]
  594. user =
  595. password =
  596. hostname =
  597. port =
  598. ssl =
  599. [/quote]
  600. user is user name, password is your password, hostname is the IP-address (uTorrent only wants IP-addresses), and port is the webui port. Set [b]ssl = true[/b] to enable encrypted uploads or false to use normal non-encrypted uploads. Read here on how to enable HTTPS webui: http://www.utorrent.com/documentation/webui
  601.  
  602. [b]The FTP header[/b]
  603. [quote]
  604. [ftp]
  605. user =
  606. password =
  607. hostname =
  608. port =
  609. [/quote]
  610. user is user name, password is your password, hostname is the hostname/IP-address, and port is the FTP port.
  611.  
  612.  
  613. [b]The IRC options header[/b]
  614. auto-connect = true
  615. Set it to true to enable auto connecting to IRC servers and channels.
  616.  
  617. user-name =
  618. real-name =
  619. IRC user name and real name. Leave blank if we should use Irssi's settings.
  620.  
  621. output-server =
  622. output-channel =
  623. Send all autodl-irssi output to the specified IRC server and channel. Make sure you've setup autodl-irssi to auto connect to the IRC server and channel.
  624.  
  625.  
  626. [b]The tracker header[/b]
  627. Your trackers require that you authenticate before letting you download a torrent file. Use the tracker headers to set the required options so downloads work.
  628.  
  629. A tracker header looks like [b][tracker TYPE][/b] where [b]TYPE[/b] is the tracker type. This is the exact same type that you find in the [b]~/.irssi/scripts/AutodlIrssi/trackers/*.tracker[/b] files. Open one of the files with a text editor and locate the [b]type="XYZ"[/b] line. Use the value inside the quotes, eg. [b]XYZ[/b]. Example: [b][tracker XYZ][/b]. Case matters so XYZ is different from xyz.
  630.  
  631. Some trackers require a [b]passkey[/b], others an [b]authkey[/b], or a [b]cookie[/b], etc. To quickly find out which one your tracker needs, just add [b][tracker TYPE][/b] (with no options below it) to autodl.cfg and wait 1-2 seconds (start Irssi if necessary). It will report the missing options, eg.: [b]ERROR: /home/YOURNAME/.autodl/autodl.cfg: line 123: TRACKER-TYPE: Missing option(s): passkey, uid[/b]. Here it's saying that you forgot to add the options [b]passkey = XXX[/b] and [b]uid = YYY[/b]. Add them below the tracker header.
  632.  
  633. Some common tracker options and how to get them:
  634.  
  635. [b]cookie[/b]: Go to your tracker's home page, then type [b]javascript:document.innerHTML=document.cookie[/b] in the address bar and press enter. You should now see your cookie. If all you see is PHPSESSID=XXXXX, then you'll have to manually get the cookie using FireFox: Edit -> Preferences -> Privacy tab -> Show Cookies. It's usually just [b]uid=XXX; pass=YYY[/b]. Separate each key=value pair with a semicolon.
  636.  
  637. [b]passkey[/b]: First check a torrent download link if it contains it. If not you can usually find it in the generated RSS-feed URL, which you probably can generate @ yourtracker.com/getrss.php . passkeys are usually exactly 32 characters long. The passkey can also sometimes be found in your profile (click your name).
  638.  
  639. [b]authkey[/b]: See [b]passkey[/b] above. For gazelle sites, it's part of the torrent download link.
  640.  
  641. [b]torrent_pass[/b]: For gazelle sites, it's part of the torrent download link.
  642.  
  643. [b]uid[/b]: Click your username and you should see the id=XXX in the address bar. That's your user id, or uid.
  644.  
  645. [tracker TYPE]
  646. #enabled =
  647. #force-ssl =
  648. #upload-delay-secs =
  649. #cookie =
  650. #passkey =
  651. #etc ...
  652.  
  653. [b]enabled[/b] is optional and defaults to true. Set it to false to disable the tracker.
  654. [b]force-ssl[/b] is optional and can be set to true to force encrypted torrent downloads. Not all trackers support HTTPS downloads. Leave it blank for the default value (which is HTTP or HTTPS).
  655. [b]upload-delay-secs[/b] is optional and is the number of seconds autodl-irssi should wait before uploading/saving the torrent. Default is 0 (no wait). This option isn't needed 99.999% of the time.
  656.  
  657.  
  658.  
  659. [b]Macros[/b]
  660.  
  661. Current date and time: [b]$(year)[/b], [b]$(month)[/b], [b]$(day)[/b], [b]$(hour)[/b], [b]$(minute)[/b], [b]$(second)[/b], [b]$(milli)[/b]
  662. [b]$(TYear)[/b] is the year of the torrent release, not current year.
  663. [b]$(Artist)[/b], [b]$(Show)[/b], [b]$(Movie)[/b], [b]$(Name1)[/b] all mean the same thing.
  664. [b]$(Album)[/b], [b]$(Name2)[/b] both mean the same thing.
  665. [b]$(Site)[/b] is tracker URL.
  666. [b]$(Tracker)[/b] is long tracker name.
  667. [b]$(TrackerShort)[/b] is short tracker name.
  668. [b]$(TorrentPathName)[/b] is the path to the .torrent file (unix path if you're using cygwin).
  669. [b]$(WinTorrentPathName)[/b] is the windows path to the .torrent file.
  670. [b]$(InfoHash)[/b] This is the "info hash" of the torrent file.
  671.  
  672. The rest are possibly self explanatory: [b]$(Category)[/b], [b]$(TorrentName)[/b], [b]$(Uploader)[/b], [b]$(TorrentSize)[/b], [b]$(PreTime)[/b], [b]$(TorrentUrl)[/b], [b]$(TorrentSslUrl)[/b], [b]$(Season)[/b], [b]$(Episode)[/b], [b]$(Resolution)[/b], [b]$(Source)[/b], [b]$(Encoder)[/b], [b]$(Format)[/b], [b]$(Bitrate)[/b], [b]$(Media)[/b], [b]$(Tags)[/b], [b]$(Scene)[/b], [b]$(Log)[/b], [b]$(Cue)[/b]
  673.  
  674. [b]$(Season2)[/b] and [b]$(Episode2)[/b] are two-digit season and episode numbers.
  675.  
  676.  
  677.  
  678.  
  679.  
  680. [b]Using autodl-cz's options[/b]
  681. This part explains how to re-use autodl-cz's options.
  682.  
  683. You need the XML::LibXSLT Perl module to run this script. Some other Perl modules are also required but they're installed by the installer.
  684.  
  685. It's important that you are using at least version 2.03 of autodl-cz! After upgrading it, run it once and go to Auto Downloader -> Preferences. Press OK and it will save all options in the 2.03 (or later) format. Failure to do this may result in a pretty useless autodl.cfg file.
  686.  
  687. Start ChatZilla and type [b]/pref profilePath[/b] and press enter. Copy your profilePath, which is something like [b]/home/YOURNAME/.mozilla/firefox/XXXXXXXXX.default/chatzilla[/b], and append [b]/autodl/settings/autodl.xml[/b] so you get something like [b]/home/YOURNAME/.mozilla/firefox/XXXXXXXXX.default/chatzilla/scripts/autodl/settings/autodl.xml[/b]. That's the path to your autodl-cz's options file. Now type this in your terminal (add your path below):
  688.  
  689. [code]
  690. mkdir -p ~/.autodl
  691. wget http://sourceforge.net/projects/autodl-irssi/files/convertxml.pl/download
  692. perl convertxml.pl /home/YOURNAME/.mozilla/firefox/XXXXXXXXX.default/chatzilla/scripts/autodl/settings/autodl.xml > ~/.autodl/autodl.cfg[/code]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement