You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@roller.apache.org by ag...@apache.org on 2007/02/09 00:32:56 UTC

svn commit: r505087 - in /incubator/roller/trunk/apps/planet: build.xml templates/ templates/group-atom.vm templates/group-rss.vm templates/group.vm templates/opml.vm

Author: agilliland
Date: Thu Feb  8 15:32:54 2007
New Revision: 505087

URL: http://svn.apache.org/viewvc?view=rev&rev=505087
Log:
example templates


Added:
    incubator/roller/trunk/apps/planet/templates/
    incubator/roller/trunk/apps/planet/templates/group-atom.vm
    incubator/roller/trunk/apps/planet/templates/group-rss.vm
    incubator/roller/trunk/apps/planet/templates/group.vm
    incubator/roller/trunk/apps/planet/templates/opml.vm
Modified:
    incubator/roller/trunk/apps/planet/build.xml

Modified: incubator/roller/trunk/apps/planet/build.xml
URL: http://svn.apache.org/viewvc/incubator/roller/trunk/apps/planet/build.xml?view=diff&rev=505087&r1=505086&r2=505087
==============================================================================
--- incubator/roller/trunk/apps/planet/build.xml (original)
+++ incubator/roller/trunk/apps/planet/build.xml Thu Feb  8 15:32:54 2007
@@ -263,11 +263,6 @@
         </copy>         
         <chmod perm="+x" dir="${build.webapp}/WEB-INF/scripts" includes="*.sh" />
         
-        <mkdir dir="${build.webapp}/WEB-INF/templates" />
-        <copy todir="${build.webapp}/WEB-INF/templates">
-            <fileset dir="./templates" includes="**/**" />
-        </copy> 
-        
         <!-- distributable WAR file 
         <mkdir dir="${dist}/webapp" />
         <war destfile="${dist}/webapp/roller-planet.war"

Added: incubator/roller/trunk/apps/planet/templates/group-atom.vm
URL: http://svn.apache.org/viewvc/incubator/roller/trunk/apps/planet/templates/group-atom.vm?view=auto&rev=505087
==============================================================================
--- incubator/roller/trunk/apps/planet/templates/group-atom.vm (added)
+++ incubator/roller/trunk/apps/planet/templates/group-atom.vm Thu Feb  8 15:32:54 2007
@@ -0,0 +1,41 @@
+#**
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  The ASF licenses this file to You
+  under the Apache License, Version 2.0 (the "License"); you may not
+  use this file except in compliance with the License.
+  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.  For additional information regarding
+  copyright in this work, please see the NOTICE file in the top level
+  directory of this distribution.
+
+*#<?xml version="1.0" encoding='utf-8'?>
+<feed xmlns="http://www.w3.org/2005/Atom">
+    <title type="html">$utils.escapeXML($model.group.title)</title>
+    <subtitle type="html">$utils.escapeXML($model.group.description)</subtitle>
+    <id>$utils.escapeXML($model.group.title)</id>
+    <link rel="self" type="application/atom+xml" href="$url.feed.atom" />
+    <link rel="alternate" type="text/html" href="" />
+    <updated></updated>
+    <generator uri="http://rollerweblogger.org">Roller Planet</generator>
+    #set($entries = $model.pager.items)
+    #foreach($entry in $entries)
+    <entry>
+        <id>$entry.permalink</id>
+        <title type="html">$utils.escapeXML($entry.title)</title>
+        <author><name>$entry.author</name></author>
+        <link rel="alternate" type="text/html" href="$entry.permalink"/>
+        <published>$utils.formatIso8601Date($entry.published)</published>
+        <updated>$utils.formatIso8601Date($entry.published)</updated> 
+        <category term="$utils.escapeXML($entry.category.name)" label="$utils.escapeXML($entry.category.name)" />
+        <content type="html">$utils.escapeXML($entry.text)</content>
+    </entry>
+#end
+</feed>
+

Added: incubator/roller/trunk/apps/planet/templates/group-rss.vm
URL: http://svn.apache.org/viewvc/incubator/roller/trunk/apps/planet/templates/group-rss.vm?view=auto&rev=505087
==============================================================================
--- incubator/roller/trunk/apps/planet/templates/group-rss.vm (added)
+++ incubator/roller/trunk/apps/planet/templates/group-rss.vm Thu Feb  8 15:32:54 2007
@@ -0,0 +1,38 @@
+#**
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  The ASF licenses this file to You
+  under the Apache License, Version 2.0 (the "License"); you may not
+  use this file except in compliance with the License.
+  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.  For additional information regarding
+  copyright in this work, please see the NOTICE file in the top level
+  directory of this distribution.
+
+*#<?xml version="1.0" encoding="utf-8"?>
+<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
+<channel>
+    <title>$utils.escapeXML($model.group.title)</title>
+    <link>$utils.escapeXML($url.feed.rss)</link>
+    <description>$utils.escapeXML($model.group.description)</description>
+    <lastBuildDate>$utils.formatRfc822Date($date)</lastBuildDate>
+    <generator>Planet Roller</generator>
+    #set($entries = $model.pager.items)
+    #foreach( $entry in $entries )
+    <item>
+        <title>$utils.escapeXML($entry.title)</title>
+        <description>$utils.escapeXML($entry.content)</description>
+     	<category>$utils.escapeXML($entry.category.name)</category>
+        <link>$utils.escapeXML($entry.permalink)</link>
+        <pubDate>$utils.formatRfc822Date($entry.published)</pubDate>
+        <dc:creator>$utils.escapeXML($entry.author)</dc:creator>
+    </item>
+    #end
+</channel>
+</rss>

Added: incubator/roller/trunk/apps/planet/templates/group.vm
URL: http://svn.apache.org/viewvc/incubator/roller/trunk/apps/planet/templates/group.vm?view=auto&rev=505087
==============================================================================
--- incubator/roller/trunk/apps/planet/templates/group.vm (added)
+++ incubator/roller/trunk/apps/planet/templates/group.vm Thu Feb  8 15:32:54 2007
@@ -0,0 +1,53 @@
+#**
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  The ASF licenses this file to You
+  under the Apache License, Version 2.0 (the "License"); you may not
+  use this file except in compliance with the License.
+  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.  For additional information regarding
+  copyright in this work, please see the NOTICE file in the top level
+  directory of this distribution.
+
+*#<html>
+#set($group = $model.group)
+#set($entries = $model.pager.items)
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=utf-8" >
+<title>$group.title</title>
+</head>
+<body>
+<table>
+   <tr>
+      <td width="80%" valign="top">
+         <h1>$group.title</h1>
+         <p><i>$group.description<i/></p>
+         <p>Last updated: $utils.formatRfc822Date($date)</p>
+         #foreach($entry in $entries)
+            <h2>$entry.title</h2>
+            Blog: $entry.subscription.title <br/>
+            Date: $entry.published<br/>
+            <a href="$entry.permalink">Permalink</a><br/>
+            <p>$entry.content</p>
+         #end
+      </td>
+      <td width="20%" valign="top">
+         <h3>Other formats</h3>
+         <a href="feed/rss">
+            <img src="rss20.png" alt="RSS 2.0 Feed" border="0"></a><p />
+         <a href="opml">
+            <img src="opml.png" alt="OPML Subscriptions" border="0"></a>
+         <h3>Subscriptions</h3>
+         #foreach ($sub in $group.subscriptions)
+         <a href="$sub.siteURL">$sub.title</a> <a href="$sub.feedURL">(feed)</a>
+         <br/>
+         #end
+      </td>
+</tr>
+</body></html>

Added: incubator/roller/trunk/apps/planet/templates/opml.vm
URL: http://svn.apache.org/viewvc/incubator/roller/trunk/apps/planet/templates/opml.vm?view=auto&rev=505087
==============================================================================
--- incubator/roller/trunk/apps/planet/templates/opml.vm (added)
+++ incubator/roller/trunk/apps/planet/templates/opml.vm Thu Feb  8 15:32:54 2007
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding='utf-8'?>
+<opml version="1.1">
+<head>
+   <title>Subscriptions list for $model.group.title</title>
+   <dateCreated>Fri, 15 Dec 2006 15:45:07 -0800</dateCreated>
+   <dateModified>Fri, 15 Dec 2006 15:45:07 -0800</dateModified>
+   <ownerName>$model.planet.handle</ownerName>
+   <ownerEmail>$model.planet.handle</ownerEmail>
+
+</head>
+<body>
+<outline>
+   #foreach($sub in $model.group.subscriptions)
+   <outline text="$sub.title" 
+          xmlUrl="$sub.feedURL" 
+         htmlUrl="$sub.siteURL" />
+   #end
+</outline>
+</body>
+</opml>