rss.tpl 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. {*
  2. * rss.tpl
  3. * gitphp: A PHP git repository browser
  4. * Component: RSS template
  5. *
  6. * Copyright (C) 2009 Christopher Han <xiphux@gmail.com>
  7. *}
  8. <?xml version="1.0" encoding="utf-8"?>
  9. <rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom">
  10. <channel>
  11. <title>{$project->GetProject()}</title>
  12. <link>{geturl fullurl=true project=$project}</link>
  13. <atom:link rel="self" href="{geturl fullurl=true project=$project action=rss}" type="application/rss+xml" />
  14. <description>{$project->GetProject()} log</description>
  15. <language>en</language>
  16. {foreach from=$log item=logitem}
  17. <item>
  18. <title>{$logitem->GetCommitterEpoch()|date_format:"%d %b %R"} - {$logitem->GetTitle()|escape:'html'}</title>
  19. <author>{$logitem->GetAuthorEmail()|escape:'html'} ({$logitem->GetAuthorName()|escape:'html'})</author>
  20. <pubDate>{$logitem->GetCommitterEpoch()|date_format:"%a, %d %b %Y %H:%M:%S %z"}</pubDate>
  21. <guid isPermaLink="true">{geturl fullurl=true project=$project action=commit hash=$logitem}</guid>
  22. <link>{geturl fullurl=true project=$project action=commit hash=$logitem}</link>
  23. <description>{$logitem->GetTitle()|escape:'html'}</description>
  24. <content:encoded>
  25. <![CDATA[
  26. {foreach from=$logitem->GetComment() item=line}
  27. {$line}<br />
  28. {/foreach}
  29. {foreach from=$logitem->DiffToParent($gitexe) item=diffline}
  30. {$diffline->GetToFile()}<br />
  31. {/foreach}
  32. ]]>
  33. </content:encoded>
  34. </item>
  35. {/foreach}
  36. </channel>
  37. </rss>