Last active
November 11, 2020 17:57
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Wget's all episodes of the Syntax.fm podcast hosted by Wes Bos and Scott Tolinkski | |
# Fetch full episode list | |
curl https://syntax.fm/api/shows | | |
jq -c '.[] | {url: .url, number: .number, title: .title, displayDate: .displayDate}' | | |
while read row; do | |
url=$(echo $row | jq -r '.url') | |
number=$(echo $row | jq -r '.number') | |
title=$(echo $row | jq -r '.title') | |
displayDate=$(echo $row | jq -r '.displayDate') | |
# Downloads to current directory | |
wget $url -O "Syntax-$number-$title-$displayDate.mp3" | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Usage
Install jq
Download all episodes to the current directory:
curl https://gist.githubusercontent.com/dawsbot/a75238ad388f7764be1e9dcf5d1a9d36/raw/67d6899194eee7aef6aae92ded6e5f92c646eaec/download-all-syntax-episodes.sh | bash