tomee-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dblev...@apache.org
Subject svn commit: r1291514 - in /openejb/site/trunk: lib/view.pm templates/basic.html templates/example.html
Date Mon, 20 Feb 2012 23:08:24 GMT
Author: dblevins
Date: Mon Feb 20 23:08:24 2012
New Revision: 1291514

URL: http://svn.apache.org/viewvc?rev=1291514&view=rev
Log:
Add links to source and instructions for running at the bottom

Modified:
    openejb/site/trunk/lib/view.pm
    openejb/site/trunk/templates/basic.html
    openejb/site/trunk/templates/example.html

Modified: openejb/site/trunk/lib/view.pm
URL: http://svn.apache.org/viewvc/openejb/site/trunk/lib/view.pm?rev=1291514&r1=1291513&r2=1291514&view=diff
==============================================================================
--- openejb/site/trunk/lib/view.pm (original)
+++ openejb/site/trunk/lib/view.pm Mon Feb 20 23:08:24 2012
@@ -158,9 +158,20 @@ sub example {
 
     my $template_path = "templates/$args{template}";
 
-    my $rendered = Dotiac::DTL->new($template_path)->render(\%args);
+    my $svndir = $args{path};
+    $svndir =~ s,/index.html,,;
+    $svndir =~ s,/examples-trunk/,trunk/openejb/examples/,;
+
+    $args{repo} = $svndir;
+
+    my $example = $svndir;
+    $example =~ s,.*/,,;
+    $args{example} = $example;
 
 #    print Dumper( \%args );
+
+    my $rendered = Dotiac::DTL->new($template_path)->render(\%args);
+
     return ($rendered, 'html', \%args);
 }
 

Modified: openejb/site/trunk/templates/basic.html
URL: http://svn.apache.org/viewvc/openejb/site/trunk/templates/basic.html?rev=1291514&r1=1291513&r2=1291514&view=diff
==============================================================================
--- openejb/site/trunk/templates/basic.html (original)
+++ openejb/site/trunk/templates/basic.html Mon Feb 20 23:08:24 2012
@@ -58,7 +58,7 @@
       };
       function twshare () {
           window.open(
-                  "https://twitter.com/intent/tweet?url="+document.URL+"&text={{ headers.title
}} " + document.URL,
+                  "https://twitter.com/intent/tweet?url="+document.URL+"&text={{ headers.title
}}",
                   'Share on Twitter',
                   'width=800,height=526');
       };

Modified: openejb/site/trunk/templates/example.html
URL: http://svn.apache.org/viewvc/openejb/site/trunk/templates/example.html?rev=1291514&r1=1291513&r2=1291514&view=diff
==============================================================================
--- openejb/site/trunk/templates/example.html (original)
+++ openejb/site/trunk/templates/example.html Mon Feb 20 23:08:24 2012
@@ -27,4 +27,14 @@
 <h4>APIs Used</h4>
 {{ apis|safe }}
 
+<h3>Source</h3>
+  <ul>
+      <li>Apache <a href="http://svn.apache.org/repos/asf/openejb/{{ repo|safe }}">{{
example|safe }}</a></li>
+      <li>Github <a href="https://github.com/apache/openejb/tree/{{ repo|safe }}">{{
example|safe }}</a></li>
+  </ul>
+<pre>
+svn co http://svn.apache.org/repos/asf/openejb/{{ repo|safe }}
+cd {{example|safe}}
+mvn clean install
+</pre>
 {% endblock %}



Mime
View raw message