youtube-dl will output in the current directory
youtube-dl --list-formats URL
youtube-dl -citw ytuser:<USER>
or
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> | |
<html xmlns="http://www.w3.org/1999/xhtml" dir="ltr" lang="en-US"> | |
<!-- Made by: Joni Ahola, 2012 --> | |
<!-- Easily embed youtube playlist: just add GET-parameter 'url' and youtube-playlist url --> | |
<!-- Example: filename.html?url=http://www.youtube.com/playlist?list=PLE5C2870574BF4B06 --> | |
<head profile="http://gmpg.org/xfn/11"> | |
<style type="text/css"> | |
/* placeholder inline styles */ |
var playListURL = '//gdata.youtube.com/feeds/api/playlists/PLOGi5-fAu8bFt81BE77HOVzO4S4M1ZexJ?v=2&alt=json&callback=?'; | |
jq.getJSON(playListURL, function (data) { | |
var list_data = ""; | |
jq.each(data.feed.entry, function (i, item) { | |
var feedTitle = item.title.$t; | |
var feedURL = item.link[1].href; | |
var fragments = feedURL.split("/"); | |
var videoID = fragments[fragments.length - 2]; | |
var thumb = "//i1.ytimg.com/vi/" + videoID + "/mqdefault.jpg"; |
These are the scripts I use to create the playlists for the AI Class (available here: http://www.mrspeaker.net/2011/10/26/ai-class-playlists/). It's not pretty, but it works. I put them up here due to popular demand. | |
The first stage is to grab the video list HTML from YouTube and extract/sort the videos. This is done with the Video_ID_scraper.html file (instructions there). | |
Next, paste the video info into the YouTube_Playlist_Uploader.py script and it generates the playlist. It relies on the GData APIs so you need a dev key etc. | |
Any questions to [email protected] |
You can download whole courses from an array of tutorial sites with the CLI tool youtube-dl
. In the example further down I'm using my Pluralsight account to get videos from a course at their site. Here is a list of all supported sites that you can download from with this tool
The flags you have to supply may vary depending on which site you make a request to.
You can get a free 3 month trial to Pluralsight by signing up for free to Visual Studio Dev Essentials
# https://github.com/rg3/youtube-dl/ | |
# On ubuntu: apt-get install libav-tools | |
# Download Playlist to batch of MP3s | |
youtube-dl -f bestvideo+bestaudio --extract-audio --audio-format mp3 --prefer-avconv --playlist-random https://www.youtube.com/playlist?list=XXXXX | |
# Download individual song | |
youtube-dl -f bestvideo+bestaudio --extract-audio --audio-format mp3 --prefer-avconv https://www.youtube.com/watch?v=ZZZZZZZ |
youtube-dl is a nifty utility that can parse and download all user videos. Recently added a feature on downloading all playlists. | |
Here is a command that downloads all playlists of user KhanAcademyUrdu and puts all videos of each playlist in separate folders. | |
youtube-dl -ciw -f '(webm)[height<480]' -o '/media/zubairlk/part1/khanurdu/%(playlist)s/%(playlist_index)s_%(title)s_%(id)s.%(ext)s' --yes-playlist -R 10000 https://www.youtube.com/user/KhanAcademyUrdu/playlists | |
some explanation for later. see https://github.com/rg3/youtube-dl for full details. | |
-i is to ignore interrupts. timeouts/private videos etc block otherwise. |
find . -name '*.png' -exec mv {} ../textures \; | |
find . -name '*.jpeg' -exec mv {} ../textures \; | |
find . -depth -type d -empty -exec rmdir {} \; |