Skip to content

Instantly share code, notes, and snippets.

@pcrunn
Forked from ldong/download_egghead_videos.md
Last active August 7, 2019 08:27
Show Gist options
  • Save pcrunn/7934e49837afdf53dc4660a32a32836f to your computer and use it in GitHub Desktop.
Save pcrunn/7934e49837afdf53dc4660a32a32836f to your computer and use it in GitHub Desktop.
download egghead videos

Download videos from egghead

Go to the egghead website, i.e. Building a React.js App

run

let videos = document.querySelector('#App-react-component > div > div:nth-child(2) > section > div > div.relative.w-100 > section.w-100.pt2.pb3.pt0-l.pb0-l.css-ic4s7x > div > div.w-100.w-30-l.pl0.pl2-l.css-1nlwas4 > div > div > div.w-100.overflow-hidden.flex.flex-column.flex-grow-1.justify-start > ul');

for(const child of videos.children) {
	console.log(child.firstChild.href);
}

You will get the following list

https://egghead.io/lessons/react-building-a-react-js-app-notetaker-introduction
https://egghead.io/lessons/react-building-a-react-js-app-up-and-running-with-react-and-webpack
https://egghead.io/lessons/react-building-a-react-js-app-basic-routing-with-react-router
https://egghead.io/lessons/react-building-a-react-js-app-state-props-and-thinking-in-react
https://egghead.io/lessons/react-building-a-react-js-app-component-validation-with-proptypes
https://egghead.io/lessons/react-building-a-react-js-app-using-reactfire-to-add-data-persistence
https://egghead.io/lessons/react-building-a-react-js-app-managing-state-in-child-components
https://egghead.io/lessons/react-building-a-react-js-app-transitions-with-react-router
https://egghead.io/lessons/react-building-a-react-js-app-making-server-requests-in-react-with-axios
https://egghead.io/lessons/react-building-a-react-js-app-rendering-a-ui-of-dynamic-data
https://egghead.io/lessons/react-building-a-react-js-app-componentwillreceiveprops-and-react-router
https://egghead.io/lessons/react-building-a-react-js-app-es6-refactor-non-components
https://egghead.io/lessons/react-building-a-react-js-app-es6-refactor-createclass-to-javascript-classes-and-proptypes
https://egghead.io/lessons/react-building-a-react-js-app-es6-refactor-proptypes-in-es6
https://egghead.io/lessons/react-building-a-react-js-app-es6-refactor-routing-without-mixins
https://egghead.io/lessons/react-building-a-react-js-app-es6-refactor-firebase-and-react-binding-with-re-base

Steps:

  1. Save as list.txt

  2. brew install youtube-dl

  3. youtube-dl -a list.txt

Run this rename script to get rid of the Mojibake

for i in *mp4; do
   mv "$i" "`echo $i | sed "s/#.*//"`"'.mp4';
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment