]> code.delx.au - webdl/blob - README.md
8ee457cc4f826b9afaea120b47eaf2c5d5299034
[webdl] / README.md
1 # WebDL #
2
3 WebDL is a set of Python scripts to grab video from online Free To Air Australian channels.
4
5
6 ## News
7
8 ### 2017-02-24
9 * Now requires Python3, use the `python2` branch if you need the old version.
10 * Recommended installation is now with `virtualenv` and `pip` to install dependencies.
11 * Removed some custom logic in favour of the `requests` and `requests_cache` libraries.
12 * `autograbber.py` can write to multiple directories, previous command line args are still supported.
13
14
15 ## Installation using pip
16
17 Install the following packages using your package manager:
18
19 * Python 3.2+ (including dev package)
20 * ffmpeg or libav-tools
21
22 Clone the WebDL repository:
23 ```
24 git clone https://bitbucket.org/delx/webdl
25 cd webdl
26 ```
27
28 Set up a Python virtualenv and use pip to install the other dependencies:
29 ```
30 virtualenv --python python3 .virtualenv
31 . .virtualenv/bin/activate
32 pip install -r requirements.txt
33 ```
34
35 Whenever you want to run WebDL you must source the `.virtualenv/bin/activate` script from your shell.
36
37
38 ## Installation on Debian/Ubuntu
39
40 Install Python 3 and needed libraries:
41 ```
42 apt-get install python3 python3-lxml python3-requests python3-requests-cache
43 ```
44
45 You must also install Streamlink, or if it unavailable, the older Livestreamer. Depending on the age of your distro you'll need either:
46
47 - `apt-get install streamlink`
48 - `apt-get install livestreamer python-crypto`
49
50
51 Install ffmpeg:
52 ```
53 apt-get install ffmpeg
54 ```
55
56 ## Interactive usage (grabber.py)
57
58 You can run WebDL interactively to browse categories and episode lists and download TV episodes.
59
60 ```
61 $ ./grabber.py
62 1) ABC iView
63 2) SBS
64 0) Back
65 Choose> 1
66 1) ABC 4 Kids
67 2) Arts & Culture
68 3) Comedy
69 4) Documentary
70 <snipped>
71 Choose> 4
72 1) ABC Open Series 2012
73 2) Art Of Germany
74 3) Baby Beauty Queens
75 4) Catalyst Series 13
76 <snipped>
77 Choose> 4
78 1) Catalyst Series 13 Episode 15
79 2) Catalyst Series 13 Episode 16
80 0) Back
81 Choose> 1
82 RTMPDump v2.3
83 (c) 2010 Andrej Stepanchuk, Howard Chu, The Flvstreamer Team; license: GPL
84 Connecting ...
85 INFO: Connected...
86 Starting download at: 0.000 kB
87 ```
88
89 The bolded parts are what you type. Note that you can go back on any screen by typing “0”. At the list of episodes you can download a single episode by typing one number, or multiple episodes by typing several numbers separated by spaces.
90
91
92
93 ## Cron scripted usage (autograbber.py)
94
95 You can schedule a regular download of your favourite shows. This example uses `chronic` from `moreutils`.
96
97 ```
98 # m h dom mon dow command
99 0 1 * * * timeout 6h chronic $HOME/webdl/autograbber-cron.sh /videos/ABC4Kids /videos/Insight
100 ```
101
102 Each of these directories should contain a `.patterns.txt` with shell-style globs:
103
104 ```
105 ABC iView/By Channel/ABC4Kids/*/*
106 SBS/Channel/SBS1/Insight*
107 ```
108
109 Whenever an episode is downloaded it is recorded into `.downloaded_auto.txt`. Even if you move the files somewhere else they will not be redownloaded.
110
111
112 ## Bug reports
113
114 Please raise issues on the [Bitbucket project](https://bitbucket.org/delx/webdl/issues?status=new&status=open).