podcast_feed.ex 3.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. defmodule PodcastFeed do
  2. @moduledoc """
  3. PodcastFeed keeps the contexts that define your domain
  4. and business logic.
  5. Contexts are also responsible for managing your data, regardless
  6. if it comes from the database, an external API or others.
  7. """
  8. alias PodcastFeed.Provider.Archive
  9. def archive() do
  10. Archive.Parser.feed('https://ia601402.us.archive.org/8/items/incontri-a-piano-terra/incontri-a-piano-terra_files.xml') #FIXME: should be dynamic
  11. |> IO.inspect
  12. end
  13. end
  14. # <item>
  15. # <title>Episode Name 2</title>
  16. # <link>
  17. # http://podcast.example.com/episode2.mp4
  18. # </link>
  19. # <pubDate>Sat, 02 Jan 2016 16:00:00 PDT</pubDate>
  20. # <description>
  21. # The full length episode 2 description
  22. # </description>
  23. # <enclosure url="http://podcasts.example.com/episode.mp4" length="36715125" type="audio/mpeg"/>
  24. # <guid>
  25. # http://podcast.example.com/episode2.mp4
  26. # </guid>
  27. # <itunes:duration>19:07</itunes:duration>
  28. # <itunes:summary>
  29. # The full length episode 2 description
  30. # </itunes:summary>
  31. # <itunes:image href="http://www.example.com/image3000x3000.png"/>
  32. # <itunes:keywords>
  33. # comma,separated,key,words
  34. # </itunes:keywords>
  35. # <itunes:explicit>no</itunes:explicit>
  36. # </item>
  37. # <?xml version="1.0" encoding="utf-8"?>
  38. # <rss xmlns:atom="http://www.w3.org/2005/Atom" xmlns:itunes="http://www.itunes.com/dtds/podcast-1.0.dtd" xmlns:itunesu="http://www.itunesu.com/feed" version="2.0">
  39. # <channel>
  40. # <link>http://www.YourSite.com</link>
  41. # <language>en-us</language>
  42. # <copyright>&#xA9;2013</copyright>
  43. # <webMaster>your@email.com (Your Name)</webMaster>
  44. # <managingEditor>your@email.com (Your Name)</managingEditor>
  45. # <image>
  46. # <url>http://www.YourSite.com/ImageSize300X300.jpg</url>
  47. # <title>Title or description of your logo</title>
  48. # <link>http://www.YourSite.com</link>
  49. # </image>
  50. # <itunes:owner>
  51. # <itunes:name>Your Name</itunes:name>
  52. # <itunes:email>your@email.com</itunes:email>
  53. # </itunes:owner>
  54. # <itunes:category text="Education">
  55. # <itunes:category text="Higher Education" />
  56. # </itunes:category>
  57. # <itunes:keywords>separate, by, comma, and, space</itunes:keywords>
  58. # <itunes:explicit>no</itunes:explicit>
  59. # <itunes:image href="http://www.YourSite.com/ImageSize300X300.jpg" />
  60. # <atom:link href="http://www.YourSite.com/feed.xml" rel="self" type="application/rss+xml" />
  61. # <pubDate>Sun, 01 Jan 2012 00:00:00 EST</pubDate>
  62. # <title>Verbose title of the podcast</title>
  63. # <itunes:author>College, school, or department owning the podcast</itunes:author>
  64. # <description>Verbose description of the podcast.</description>
  65. # <itunes:summary>Duplicate of above verbose description.</itunes:summary>
  66. # <itunes:subtitle>Short description of the podcast - 255 character max.</itunes:subtitle>
  67. # <lastBuildDate>Thu, 02 Feb 2012 00:00:00 EST</lastBuildDate>
  68. # <item>
  69. # <title>Verbose title of the episode</title>
  70. # <description>Verbose description of the episode.</description>
  71. # <itunes:summary>Duplicate of above verbose description.</itunes:summary>
  72. # <itunes:subtitle>Short description of the episode - 255 character max.</itunes:subtitle>
  73. # <itunesu:category itunesu:code="112" />
  74. # <enclosure url="http://www.YourSite.com/FILE.EXT" type="audio/mpeg" length="1" />
  75. # <guid>http://www.YourSite.com/FILE.EXT</guid>
  76. # <itunes:duration>H:MM:SS</itunes:duration>
  77. # <pubDate>Thu, 02 Feb 2012 00:00:00 EST</pubDate>
  78. # </item>
  79. # </channel>
  80. # </rss>