chriseidhof / pomotv

http://www.pomo.tv
182 stars 29 forks source link

Make it easier to import videos #59

Closed chriseidhof closed 8 years ago

chriseidhof commented 8 years ago

There's a script on the command-line, which makes it easy to import videos from a youtube playlist/user. We could probably do the same thing in Javascript, in the browser. That way, we can provide a web page that imports all videos from a youtube playlist/user, maybe even automatically remove the conference name (for example, by removing a prefix/suffix that every video has). We can provide a simple form for changing the values manually (e.g. separating the speaker's name from the talk, adding tags (with autocomplete!)). Finally, the page would generate yaml for copy-pasting. Ideally, it'd even help you file a PR, but maybe that's a step too far currently...

This way, we can make the barrier for adding videos way lower, and anyone who has a few minutes can help out.

JaviLorbada commented 8 years ago

There's also an script to import WWDC videos:

task :fetchwwdc, [:year] => :dotenv do |t, args|
  yaml_content = open("https://raw.githubusercontent.com/ASCIIwwdc/wwdc-session-transcripts/master/#{args[:year]}/_sessions.yml"){|f| f.read}
  yaml_data = YAML::load(yaml_content) 

  # puts yaml_data.inspect
  yaml_data.each do |id, video|
    puts "  - language: English"
    puts "    speakers: [TODO]"
    puts "    title: \"#{video[:title]}\""
    puts "    description: \"#{video[:description]}\""
    puts "    tags: [#{video[:track]}]".downcase
    puts "    wwdc: \"wwdc#{args[:year]}-#{id}\""
    puts "    direct-link: \"https://developer.apple.com/videos/play/wwdc#{args[:year]}-#{id}\""
  end
end

Unfortunately speakers have to be added manually, easiest I found:

Open slides of any talk like A Practical Guide to the App Sandbox -> Presentation slides (PDF).