Anonymous avatar Anonymous committed 7562d0b

added sitemap and sioc management.

Comments (0)

Files changed (10)

build/couchit.yml

         - layout.css
         - textarea.css
         - colorPicker.css
-    theme.css:
         - slate.css
 javascript:
     prototype.js:
         - src/page.js
     colorpicker.js:
         - lib/yahoo.color.js
-        - lib/colorPicker.js
+        - lib/colorPicker.js
+    couchit-semantic.js:
+        - src/semantic.js

couchit/contrib/markdown2.py

         
         self.src = "\n".join(lines).strip("\n")
 
+
 #---- public api
 
 
                         curr_pos = start_idx + len(result)
                         text = text[:start_idx] + result + text[match.end():]
                     elif start_idx >= anchor_allowed_pos:
-                        result_head = '<a href="%s"%s>' % (url, title_str)
+                        if url.startswith('feed://') or url.startswith('feeds://'):
+                            url = url.replace('feed', 'http')
+                            result_head = '<a href="%s"%s rel="feed">' % (url, title_str)
+                            result = '%s%s</a>' % (result_head, link_text)
+                        else:
+                            result_head = '<a href="%s"%s>' % (url, title_str)
                         result = '%s%s</a>' % (result_head, link_text)
                         # <img> allowed from curr_pos on, <a> from
                         # anchor_allowed_pos on.
 from couchit import settings
 from couchit.models import *
 from couchit.api import *
+from couchit.contrib import mimeparse
 from couchit.http import BCResponse
 from couchit.template import render_response, url_for, render_template, send_json, convert_markdown
 from couchit.utils import local, make_hash, datetime_tojson, to_str
 from couchit.utils.mail import send_mail
+from couchit.utils.sioc import SiocWiki, send_sioc
 
 import simplejson as json
 
   
 @valid_page
 def show_page(request=None, pagename=None):
+    mimetypes = request.accept_mimetypes
+    
+    
     if pagename is None:
         pagename ='home'
         
             return redirect(url_for('show_page', 
             pagename=page.title.replace(' ', '_'),
             redirect_from=pagename))
+            
+    
+    
     
     if not page or page.id is None:
         if pagename.lower() in FORBIDDEN_PAGES:
             site=request.site.id,
             title=pagename.replace("_", " ")
         )
+    
+    if mimeparse.best_match(['application/rdf+xml', 'text/xml', 'text/html'], 
+    request.headers['ACCEPT']) == "application/rdf+xml":
+        site_title = request.site.title and request.site.title or request.site.cname
+        site_url = request.host_url
+        if not local.site_url:
+            site_url += local.site_url
+        
+        sioc = SiocWiki(site_url, site_title, datetime_tojson(request.site.created))
+        sioc.add_page(page.content, page.title, request.url, datetime_tojson(page.updated))
+        return send_sioc(sioc.to_str())
 
     # get all pages
     pages = all_pages(local.db, request.site.id)
         for rev in all_revisions:
             title = ''
             _url="%s%s" % (request.host_url, url_for("revision_page", 
-                cname=request.site.cname, pagename=pagename, 
+                pagename=pagename, 
                 nb_revision=rev.nb_revision
             ))
             for change in rev.changes:
                 'id':rev.title.replace(' ', '_')
             })
         return send_json(json)
+    elif feedtype == 'rdf':
+        site_title = request.site.title and request.site.title or request.site.cname
+        site_url = request.host_url
+        if not local.site_url:
+            site_url += local.site_url
+        
+        sioc = SiocWiki(site_url, site_title, datetime_tojson(request.site.created))
+        for rev in changes:
+            _url = "%s%s" % (request.host_url, url_for("show_page", pagename=rev.title.replace(' ', '_')))
+            sioc.add_page(rev.content, rev.title, _url, datetime_tojson(rev.updated))
+        return send_sioc(sioc.to_str())
 
     return render_response('site/changes.html', changes=changes, pages=pages)
 

static/css/screen.css

 h5.settings {padding-bottom:0;margin-bottom:0.8em;border-bottom:1px solid;}
 #home_wrapper {margin:0 auto 0 auto;width:550px;text-align:center;}
 .tableSettings th {width:120px;vertical-align:middle;}
+.feed {margin-left:3px;padding:0 0 0 19px;background:url("../../img/feed-icon-14x14.png") no-repeat 0 50%;}
+.tooltip {border:1px solid #000;background-color:#fff;height:25px;width:200px;font-family:"Lucida Grande",Verdana;font-size:10px;color:#333;}
 #markdown_toolbar {position:relative;list-style:none;border:1px solid #d7d7d7;background-color:#F6F6F6;margin:0;padding:0;height:18px;margin-bottom:2px;}
 #markdown_toolbar li {list-style:none;margin:0;padding:0;float:left;}
 #markdown_toolbar li a {width:24px;height:16px;float:left;display:block;background-image:url(../img/markdown_icons.gif);border:1px solid #fff;border-right-color:#d7d7d7;}
 #colorpicker-value,#colorpicker-value-input {font-size:9px !important;font-family:Helvetica, Verdana, Sans-Serif;height:10px;}
 #colorpicker-value-input {width:40px;}
 #colorpicker-okbutton {float:right;padding:0 10px;background:#3366FF;font-size:10px;font-family:Tahoma, Helvetica, Sans-Serif;border:1px solid #666666;color:#ffffff;}
+body {background-color:#e7e7e7;color:#000;}
+a {color:#14456e;}
+header h1 a {color:#000;}
+#page article {color:#000;background-color:#fff;border-right-color:#d4d4d4;border-left-color:#d4d4d4;border-bottom-color:#d4d4d4;}
+#phistory,#pdiff,#pdesign,#claim_wrapper,#psettings,#pgeneric {background-color:#fff;border-color:#d4d4d4;color:#000;}
+#pdiff h4 {border-bottom-color:#ccc;}
+ul.subsection_tabs {background-color:#d4d4d4;}
+ul.subsection_tabs li.tab a {color:#666;}
+ul.subsection_tabs li.tab a.active {color:#000;}
+ul.page_infos {border-top-color:#ccc;border-bottom-color:#ccc;}
+ul.page_infos li {border-right-color:#ccc;}
+del {background-color:#ff8888;color:#000;}
+ins {background-color:#99ff99;color:#000;}
+tr.rselected {background-color:#d4d4d4;opacity:0.5;filter:0.5;}
+.box {background-color:#fff;}
+.box a {color:#14456e;}
+.box h4 {background-color:#d4d4d4;color:#000;}
+input#srevert, input#scompare {background-color:#cec6b5;border-color:#7a7261;}
+th.linenos {background-color:#f4f4f4;color:#666;}
+.linenos .special {color:#000;}
+table.difftabular {background-color:#fff;}
+table.difftabular th {background-color:#f7f7f0;}
+tr.tabularh th.linenos {color:#000;}
+tr.changed {background-color:#ddf8cc;}
+tr.changed td.first,tr.base td.first {border-top-color:#33aa33;}
+tr.changed .last,tr.base .last {border-bottom-color:#33aa33;}
+.claim, .logout {background-color:#000;color:#fff;}
+tr.errors {background:#ff9898;border:#ff0000;}
+p.notice {background:#FFF6BF;color:#514721;border-color:#FFD324;}
+.window {background-color:#dedede;color:#bbbbbb;border:#ababab;}
+.window form table {background-color:#2c2c2c;}
+.window form p a, .window a:visited {color:#bbb;}
+tr.rlink_type {border-color:#fff;}
+input, textarea {border-color:#C6C6C6 #EFEFEF #EFEFEF #C6C6C6;}
+.window input[type="submit"] {background-color:#3d3d3d;border-color:#bbb;color:#bbb;}

static/css/src/layout.css

 .tableSettings th {
     width: 120px;
     vertical-align: middle;
+}
+
+.feed {
+    margin-left: 3px;
+      padding: 0 0 0 19px;
+      background: url("../../img/feed-icon-14x14.png") no-repeat 0 50%;
+}
+
+.tooltip {  
+    border:1px solid #000;  
+    background-color:#fff;  
+    height:25px;  
+    width:200px;  
+    font-family:"Lucida Grande",Verdana;  
+    font-size:10px;  
+    color:#333;  
 }

static/js/couchit-application.js

-if(!document.createElementNS){document.createElement("section");document.createElement("audio");document.createElement("video");document.createElement("article");document.createElement("aside");document.createElement("footer");document.createElement("header");document.createElement("nav");document.createElement("time")}Date.parseRFC3339=function(C){var B=new Date(0);var A=C.match(/(\d{4})-(\d\d)-(\d\d)\s*(?:[\sT]\s*(\d\d):(\d\d)(?::(\d\d))?(\.\d*)?\s*(Z|([-+])(\d\d):(\d\d))?)?/);if(!A){return }if(A[2]){A[2]--}if(A[7]){A[7]=(A[7]+"000").substring(1,4)}var E=[null,"FullYear","Month","Date","Hours","Minutes","Seconds","Milliseconds"];for(var D=1;D<=7;D++){if(A[D]){B["setUTC"+E[D]](A[D])}}if(A[9]){B.setTime(B.getTime()+(A[9]=="-"?1:-1)*(A[10]*3600000+A[11]*60000))}return B.getTime()};function localizeDates(){var B="";var A=new Date();$$("time").each(function(E,D){if(E.getAttribute("title")=="GMT"){var C=new Date(Date.parseRFC3339(E.getAttribute("datetime")));if(!C.getTime()){return }diff=((A.getTime()-C.getTime())/1000),day_diff=Math.floor(diff/86400);if(isNaN(day_diff)||day_diff<0||day_diff>=31){return }var G=C.toLocaleString();var F=C.toLocaleString();if(day_diff==0){G=(diff<60&&"Just Now"||diff<120&&"1 minute ago"||diff<3600&&Math.floor(diff/60)+" minutes ago"||diff<7200&&"1 hour ago"||diff<86400&&Math.floor(diff/3600)+" hours ago");F=C.toLocaleTimeString()}else{hours=C.getHours();minutes=C.getMinutes();hours=(hours<10)&&"0"+hours||hours;minutes=(minutes<10)&&"0"+minutes||minutes;G=(day_diff==1&&"Yesterday at "+hours+":"+minutes||E.textContent);F=C.toLocaleString()}E.setAttribute("title",F);E.textContent="posted "+G}})}var Page={};var Site={url:"",name:""};var FORBIDDEN_PAGES=["site","delete","edit","create","history","changes"];var Create=Class.create({initialize:function(){var A=this;this.Form=$("fnewpage");this.doCreate=$("doCreate");this.Form.addClassName("hidden");Event.observe(this.doCreate,"click",function(B){Event.stop(B);A.show();return false},false);Event.observe($$("a.cancelCreate")[0],"click",function(B){Event.stop(B);A.cancel();return false},false);$("screate").observe("click",function(B){Event.stop(B);A.submit();return false},false)},show:function(){this.doCreate.addClassName("hidden");this.Form.removeClassName("hidden")},cancel:function(){this.Form.addClassName("hidden");this.doCreate.removeClassName("hidden")},submit:function(){var B=$("title");if(!B.value.match(/^['\-\"\/ \w\u00A1-\uFFFF]+$/i)||FORBIDDEN_PAGES.indexOf(B.value)>=0){alert("Page title invalid");return false}var A=B.value.replace(/ /g,"_");url=Site.url+"/"+A+"#pedit";window.location.href=url;this.Form.addClassName("hidden");this.doCreate.removeClassName("hidden")},});var Compare=Class.create({nb_selected:0,selected:false,initialize:function(){var A=this;this.Form=$("fhistory");$$("input.c").each(function(B){B.observe("click",function(C){A.check(this)},false)})},check:function(A){row=A.parentNode.parentNode;row.toggleClassName("rselected");if(!A.checked){this.nb_selected-=1;A.removeClassName("selected")}else{this.nb_selected+=1;A.addClassName("selected")}if(this.nb_selected==2){$$("input.c").each(function(B){if(!B.hasClassName("selected")){B.disabled="disabled"}});this.selected=true}else{if(this.selected){$$("input.c").each(function(B){if(!B.hasClassName("selected")){B.disabled=null}});this.selected=false}}}});var Diff=Class.create({initialize:function(){var A=this;this.rev_from=$("rev_from");this.rev_to=$("rev_to");$("scompare").observe("click",function(B){Event.stop(B);A.get_diff();return false})},get_diff:function(){var B=this.rev_from.getValue();var A=this.rev_to.getValue();if(B==A){alert("Why would you want compare same version ...");return }url=$("fdiff").action+"?r="+B+"&r="+A;new Ajax.Request(url,{method:"get",contentType:"application/json",requestHeaders:{Accept:"application/json"},onSuccess:function(C){data=C.responseText.evalJSON(true);if(data.ok){Element.remove($("tableDiff"));$("pdiff").insert(data.diff)}}})}});var Settings=Class.create({initialize:function(){var A=this;this.observer=null;this.title=$("site_header").select("h1 a")[0];this.subtitle=$("site_header").select("h2")[0];$$("input").each(function(B){new Form.Element.Observer(B,0.2,function(C,D){if(C.id=="site_title"){A.title.update(D);document.title=D+" - settings"}if(C.id=="site_subtitle"){A.subtitle.update(D)}if(A.observer){clearTimeout(A.observer)}A.observer=setTimeout(A.save.bind(A),400)})})},save:function(){var A={};try{A={title:$("site_title").getValue(),subtitle:$("site_subtitle").getValue(),email:$("email").getValue(),privacy:$$('input:checked[type="radio"][name="privacy"]').pluck("value")[0],allow_javascript:$("allow_javascript").getValue()}}catch(B){A={title:$("site_title").getValue(),subtitle:$("site_subtitle").getValue()}}url=$("fsettings").action;new Ajax.Request(url,{method:"post",postBody:Object.toJSON(A),contentType:"application/json",requestHeaders:{Accept:"application/json"},onSuccess:function(C){A=C.responseText.evalJSON(true)}})}});var SiteAddress=Class.create({initialize:function(){var A=this;if(!$("error").innerHTML){$("error").hide()}new Form.Element.Observer("alias",0.2,function(B,C){if(C.length>3&&!C.match(/^(\w+)$/)){$("error").update("<strong>Error:</strong> "+$("alias").value+" is invalid, only use letters and numbers.");$("error").show()}else{$("error").hide()}});$("faddress").observe("submit",function(D){Event.stop(D);var B=null;var C=$("alias").getValue();if(C.length<=3){B="length < 3"}else{if(!C.match(/^(\w+)$/)){B=C+" is invalid, only use letters and numbers."}}if(B){$("error").update("<strong>Error:</strong> "+B);$("error").show();return false}else{A.valid_name()}},false)},valid_name:function(){url=$("faddress").action;new Ajax.Request(url,{method:"get",contentType:"application/json",parameters:{alias:$("alias").getValue()},requestHeaders:{Accept:"application/json"},onSuccess:function(A){data=A.responseText.evalJSON(true);if(data.ok){$("faddress").submit()}else{$("error").update("<strong>Error:</strong> "+data.error);$("error").show()}}})}});var Claim=Class.create({initialize:function(){var A=this;this.email=$("email");this.password=$("password");$("fclaim").observe("submit",function(B){Event.stop(B);if(A.validate()){this.submit()}},false)},validate:function(){$$(".help_error").each(function(B){B.remove()});$$(".errors").each(function(B){B.removeClassName("errors")});nb_errors=0;if(!this.email.value.match(/(^[-!#$%&'*+/=?^_`{}|~0-9A-Z]+(\.[-!#$%&'*+/=?^_`{}|~0-9A-Z]+)*|^"([\001-\010\013\014\016-\037!#-\[\]-\177]|\\[\001-011\013\014\016-\177])*")@(?:[A-Z0-9-]+\.)+[A-Z]{2,6}$/i)){var A=new Element("div",{"class":"help_error"}).update("Invalid email address.");this.email.parentNode.insert(A);$("row_email").addClassName("errors");nb_errors+=1}if(this.password.value.length<=0){var A=new Element("div",{"class":"help_error"}).update("You should set a password.");this.password.parentNode.insert(A);$("row_password").addClassName("errors");nb_errors+=1}if(nb_errors>0){return false}return true}});document.observe("dom:loaded",function(){localizeDates()});
+if(!document.createElementNS){document.createElement("section");document.createElement("audio");document.createElement("video");document.createElement("article");document.createElement("aside");document.createElement("footer");document.createElement("header");document.createElement("nav");document.createElement("time")}Date.parseRFC3339=function(C){var B=new Date(0);var A=C.match(/(\d{4})-(\d\d)-(\d\d)\s*(?:[\sT]\s*(\d\d):(\d\d)(?::(\d\d))?(\.\d*)?\s*(Z|([-+])(\d\d):(\d\d))?)?/);if(!A){return }if(A[2]){A[2]--}if(A[7]){A[7]=(A[7]+"000").substring(1,4)}var E=[null,"FullYear","Month","Date","Hours","Minutes","Seconds","Milliseconds"];for(var D=1;D<=7;D++){if(A[D]){B["setUTC"+E[D]](A[D])}}if(A[9]){B.setTime(B.getTime()+(A[9]=="-"?1:-1)*(A[10]*3600000+A[11]*60000))}return B.getTime()};function localizeDates(){var B="";var A=new Date();$$("time").each(function(E,D){if(E.getAttribute("title")=="GMT"){var C=new Date(Date.parseRFC3339(E.getAttribute("datetime")));if(!C.getTime()){return }diff=((A.getTime()-C.getTime())/1000),day_diff=Math.floor(diff/86400);if(isNaN(day_diff)||day_diff<0||day_diff>=31){return }var G=C.toLocaleString();var F=C.toLocaleString();if(day_diff==0){G=(diff<60&&"Just Now"||diff<120&&"1 minute ago"||diff<3600&&Math.floor(diff/60)+" minutes ago"||diff<7200&&"1 hour ago"||diff<86400&&Math.floor(diff/3600)+" hours ago");F=C.toLocaleTimeString()}else{hours=C.getHours();minutes=C.getMinutes();hours=(hours<10)&&"0"+hours||hours;minutes=(minutes<10)&&"0"+minutes||minutes;G=(day_diff==1&&"Yesterday at "+hours+":"+minutes||E.textContent);F=C.toLocaleString()}E.setAttribute("title",F);E.textContent="posted "+G}})}var Page={};var Site={url:"",name:""};var FORBIDDEN_PAGES=["site","delete","edit","create","history","changes","archives"];var Create=Class.create({initialize:function(){var A=this;this.Form=$("fnewpage");this.doCreate=$("doCreate");this.Form.addClassName("hidden");Event.observe(this.doCreate,"click",function(B){Event.stop(B);A.show();return false},false);Event.observe($$("a.cancelCreate")[0],"click",function(B){Event.stop(B);A.cancel();return false},false);$("screate").observe("click",function(B){Event.stop(B);A.submit();return false},false)},show:function(){this.doCreate.addClassName("hidden");this.Form.removeClassName("hidden")},cancel:function(){this.Form.addClassName("hidden");this.doCreate.removeClassName("hidden")},submit:function(){var B=$("title");if(!B.value.match(/^['\-\"\/ \w\u00A1-\uFFFF]+$/i)||FORBIDDEN_PAGES.indexOf(B.value)>=0){alert("Page title invalid");return false}var A=B.value.replace(/ /g,"_");url=Site.url+"/"+A+"#pedit";window.location.href=url;this.Form.addClassName("hidden");this.doCreate.removeClassName("hidden")},});var Compare=Class.create({nb_selected:0,selected:false,initialize:function(){var A=this;this.Form=$("fhistory");$$("input.c").each(function(B){B.observe("click",function(C){A.check(this)},false)})},check:function(A){row=A.parentNode.parentNode;row.toggleClassName("rselected");if(!A.checked){this.nb_selected-=1;A.removeClassName("selected")}else{this.nb_selected+=1;A.addClassName("selected")}if(this.nb_selected==2){$$("input.c").each(function(B){if(!B.hasClassName("selected")){B.disabled="disabled"}});this.selected=true}else{if(this.selected){$$("input.c").each(function(B){if(!B.hasClassName("selected")){B.disabled=null}});this.selected=false}}}});var Diff=Class.create({initialize:function(){var A=this;this.rev_from=$("rev_from");this.rev_to=$("rev_to");$("scompare").observe("click",function(B){Event.stop(B);A.get_diff();return false})},get_diff:function(){var B=this.rev_from.getValue();var A=this.rev_to.getValue();if(B==A){alert("Why would you want compare same version ...");return }url=$("fdiff").action+"?r="+B+"&r="+A;new Ajax.Request(url,{method:"get",contentType:"application/json",requestHeaders:{Accept:"application/json"},onSuccess:function(C){data=C.responseText.evalJSON(true);if(data.ok){Element.remove($("tableDiff"));$("pdiff").insert(data.diff)}}})}});var Settings=Class.create({initialize:function(){var A=this;this.observer=null;this.title=$("site_header").select("h1 a")[0];this.subtitle=$("site_header").select("h2")[0];$$("input").each(function(B){new Form.Element.Observer(B,0.2,function(C,D){if(C.id=="site_title"){A.title.update(D);document.title=D+" - settings"}if(C.id=="site_subtitle"){A.subtitle.update(D)}if(A.observer){clearTimeout(A.observer)}A.observer=setTimeout(A.save.bind(A),400)})})},save:function(){var A={};try{A={title:$("site_title").getValue(),subtitle:$("site_subtitle").getValue(),email:$("email").getValue(),privacy:$$('input:checked[type="radio"][name="privacy"]').pluck("value")[0],allow_javascript:$("allow_javascript").getValue()}}catch(B){A={title:$("site_title").getValue(),subtitle:$("site_subtitle").getValue()}}url=$("fsettings").action;new Ajax.Request(url,{method:"post",postBody:Object.toJSON(A),contentType:"application/json",requestHeaders:{Accept:"application/json"},onSuccess:function(C){A=C.responseText.evalJSON(true)}})}});var SiteAddress=Class.create({initialize:function(){var A=this;if(!$("error").innerHTML){$("error").hide()}new Form.Element.Observer("alias",0.2,function(B,C){if(C.length>3&&!C.match(/^(\w+)$/)){$("error").update("<strong>Error:</strong> "+$("alias").value+" is invalid, only use letters and numbers.");$("error").show()}else{$("error").hide()}});$("faddress").observe("submit",function(D){Event.stop(D);var B=null;var C=$("alias").getValue();if(C.length<=3){B="length < 3"}else{if(!C.match(/^(\w+)$/)){B=C+" is invalid, only use letters and numbers."}}if(B){$("error").update("<strong>Error:</strong> "+B);$("error").show();return false}else{A.valid_name()}},false)},valid_name:function(){url=$("faddress").action;new Ajax.Request(url,{method:"get",contentType:"application/json",parameters:{alias:$("alias").getValue()},requestHeaders:{Accept:"application/json"},onSuccess:function(A){data=A.responseText.evalJSON(true);if(data.ok){$("faddress").submit()}else{$("error").update("<strong>Error:</strong> "+data.error);$("error").show()}}})}});var Claim=Class.create({initialize:function(){var A=this;this.email=$("email");this.password=$("password");$("fclaim").observe("submit",function(B){Event.stop(B);if(A.validate()){this.submit()}},false)},validate:function(){$$(".help_error").each(function(B){B.remove()});$$(".errors").each(function(B){B.removeClassName("errors")});nb_errors=0;if(!this.email.value.match(/(^[-!#$%&'*+/=?^_`{}|~0-9A-Z]+(\.[-!#$%&'*+/=?^_`{}|~0-9A-Z]+)*|^"([\001-\010\013\014\016-\037!#-\[\]-\177]|\\[\001-011\013\014\016-\177])*")@(?:[A-Z0-9-]+\.)+[A-Z]{2,6}$/i)){var A=new Element("div",{"class":"help_error"}).update("Invalid email address.");this.email.parentNode.insert(A);$("row_email").addClassName("errors");nb_errors+=1}if(this.password.value.length<=0){var A=new Element("div",{"class":"help_error"}).update("You should set a password.");this.password.parentNode.insert(A);$("row_password").addClassName("errors");nb_errors+=1}if(nb_errors>0){return false}return true}});document.observe("dom:loaded",function(){localizeDates()});

static/js/src/application.js

     name: ""
 };
 
-var FORBIDDEN_PAGES = ['site', 'delete', 'edit', 'create', 'history', 'changes']
+var FORBIDDEN_PAGES = ['site', 'delete', 'edit', 'create', 'history', 'changes', 'archives']
 
 var Create = Class.create({
     initialize: function() {

templates/base.html

     <script src="/static/js/lib/slider.js" type="text/javascript"></script>
     <script src="/static/js/src/application.js" type="text/javascript"></script>
     {% else %}
-    <link rel="stylesheet" href="/static/css/screen.css?20080926" type="text/css" media="screen, projection" />
-    <link rel="stylesheet" href="/static/css/theme.css?20080926" type="text/css" media="screen, projection" />
-    <link rel="stylesheet" href="/static/css/print.css?20080926" type="text/css" media="print" /> 
+    <link rel="stylesheet" href="/static/css/screen.css?20080928" type="text/css" media="screen, projection" />
+    <link rel="stylesheet" href="/static/css/print.css?20080928" type="text/css" media="print" /> 
     <!--[if IE]>
-      <link rel="stylesheet" href="/static/css/ie.css?20080926" type="text/css" media="screen, projection" />
+      <link rel="stylesheet" href="/static/css/ie.css?20080928" type="text/css" media="screen, projection" />
     <![endif]-->
     {% if site %}
 
-    <script src="/static/js/prototype.js?20080926" type="text/javascript"></script>
-    <script src="/static/js/scriptaculous.js?20080926" type="text/javascript"></script>
-    <script src="/static/js/couchit-application.js?20080926" type="text/javascript"></script>
+    <script src="/static/js/prototype.js?20080928" type="text/javascript"></script>
+    <script src="/static/js/scriptaculous.js?20080928" type="text/javascript"></script>
+    <script src="/static/js/couchit-application.js?20080928" type="text/javascript"></script>
     {% endif %}
     
     {% endif %}

templates/page/show.html

 {% block head %}
 {% if page.title == "Home" %}
     <link rel="alternate" type="application/atom+xml" href="{{ url_for('site_changes', feedtype='atom') }}" title="Atom Recent Changes Feed" />
+    <link rel="alternate" type="application/rdf+xml" href="{{ url_for('site_changes', feedtype='rdf') }}" title="SIOC Pages" />
 {% endif %}
 
 <link rel="alternate" type="application/atom+xml" href="{{ url_for('revisions_feed', pagename=page.title|replace(" ", "_"), feedtype='atom') }}" title="Atom Revisions Feed" />
+<link rel="alternate" type="application/rdf+xml" href="{{ url_for('show_page', pagename=page.title|replace(" ", "_")) }}" title="SIOC" />
 
 {% if DEBUG %}
 <script src="/static/js/lib/livepipe.js" type="text/javascript"></script>
 <script src="/static/js/lib/window.js" type="text/javascript"></script>
 <script src="/static/js/lib/showdown.js" type="text/javascript"></script>
 <script src="/static/js/src/page.js" type="text/javascript"></script>
+<script src="/static/js/src/semantic.js" type="text/javascript"></script>
 {% else %}
-<script src="/static/js/livepipe.js?20080926" type="text/javascript"></script>
-<script src="/static/js/couchit-page.js?20080926" type="text/javascript"></script>
+<script src="/static/js/livepipe.js?20080928" type="text/javascript"></script>
+<script src="/static/js/couchit-page.js?20080928" type="text/javascript"></script>
+<script src="/static/js/couchit-semantic.js?20080928" type="text/javascript"></script>
 {% endif %}
 
 {% endblock %}
     new Create();
     new PageUI();
     {% endif %}
+    
+    new Feed();
 </script>
 {% endblock %}

tools/merge_js.py

         self.cmd_path = os.path.join(os.path.dirname(__file__), 'yuicompressor-2.3.5.jar')
     
     def compress(self, tempfile):
+        print tempfile
         cmd = "java -jar %s --type js %s" % (self.cmd_path, tempfile) 
         sout, sin = popen2(cmd)
         return sout.read()
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.