Archive all episodes from your favorite podcasts
Project description
Podcast Archiver
Archive all episodes from your favorite podcasts.
The archiver takes the feed URLs of your favorite podcasts and downloads all available episodes for you. Even those files "hidden" in a paged feed will be tapped, so you'll have an entire backup of the series. The archiver also supports updating an existing archive, so that it lends itself to be set up as a cronjob.
Outline
In my experience, very few full-fledged podcast clients are able to access a paged feed (following IETF RFC5005), so only the last few episodes of a podcast will be available to download. When you discover a podcast that has been around for quite a while, you'll have a hard time to follow the "gentle listener's duty" and listen to the whole archive. The script in this repository is supposed to help you acquiring every last episode of your new listening pleasure.
Before downloading any episode the function first fetches all available pages of the feed and prepares a list. That way, you will never miss any episode.
Setup
podcast-archiver
is Python 3.9+ compatible.
# Latest published versions on PyPI:
pip install podcast-archiver
# Latest master from GitHub:
pip install git+https://github.com/janw/podcast-archiver.git
Usage
Run podcast-archiver --help
for details on how to use it.
Full-fledged example
podcast-archiver -d ~/Music/Podcasts \
--subdirs \
--date-prefix \
--progress \
--verbose \
-f http://logbuch-netzpolitik.de/feed/m4a \
-f http://raumzeit-podcast.de/feed/m4a/ \
-f https://feeds.lagedernation.org/feeds/ldn-mp3.xml
Process the feed list from a file
If you have a larger list of podcasts and/or want to update the archive on a cronjob basis, the -f
argument can be outsourced into a text file. The text file may contain one feed URL per line, looking like this:
podcast-archiver -d ~/Music/Podcasts -s -u -f feedlist.txt
where feedlist.txt
contains the URLs as if entered into the command line:
http://logbuch-netzpolitik.de/feed/m4a
http://raumzeit-podcast.de/feed/m4a/
https://feeds.lagedernation.org/feeds/ldn-mp3.xml
This way, you can easily add and remove feeds to the list and let the archiver fetch the newest episodes for example by adding it to your crontab.
Excursion: Unicode Normalization in Slugify
The --slugify
option removes all ambiguous characters from folders and filenames used in the archiving process. The removal includes unicode normalization according to Compatibility Decomposition. What? Yeah, me too. I figured this is best seen in an example, so here's a fictitious episode name, and how it would be translated to an target filename using the Archiver:
SPR001_Umlaute sind ausschließlich in schönen Sprachen/Dialekten zu finden.mp3
will be turned into
SPR001_Umlaute-sind-ausschlielich-in-schonen-SprachenDialekten-zu-finden.mp3
Note that "decorated" characters like ö
are replaced with their basic counterparts (o
), while somewhat ligatur-ish ones like ß
(amongst most unessential punctuation) are removed entirely.
Todo
- Add ability to define a preferred format on feeds that contain links for multiple audio codecs.
- Add ability to define a range of episodes or time to download only episode from that point on or from there to the beginning or or or …
- Add ability to choose a prefix episodes with the episode number (rarely necessary, since most podcasts feature some kind of episode numbering in the filename)
- Add unittests
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file podcast_archiver-0.4.1.tar.gz
.
File metadata
- Download URL: podcast_archiver-0.4.1.tar.gz
- Upload date:
- Size: 9.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.3.2 CPython/3.11.3 Darwin/22.1.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2baa86a0c7c84d9ccd168f0b5027e3ecd3203eaf8fd375cc80620de0df0dfd47 |
|
MD5 | 593375be870844bb5d9ffbcccb248081 |
|
BLAKE2b-256 | 95a4ad972e9773d4df8f226c556ecd52df6232701abcd3c322f00a7b10e395a3 |
Provenance
File details
Details for the file podcast_archiver-0.4.1-py3-none-any.whl
.
File metadata
- Download URL: podcast_archiver-0.4.1-py3-none-any.whl
- Upload date:
- Size: 9.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.3.2 CPython/3.11.3 Darwin/22.1.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9e20029b0be1c36a0e653cf9adeb002705fe1acb0a214ba289a40c0617ad2c4b |
|
MD5 | 7451e571518ce152c7da5262d9f70a00 |
|
BLAKE2b-256 | f35fbc2d4998aca3d3a3da33244802b19075cccb52c858263fa7f1cb0025c535 |