| |
- (function(d){var e=function(a,b,c,f){this.target=a;this.url=b;this.html=[];this.effectQueue=[];this.options=d.extend({ssl:!1,host:"www.feedrapp.info",limit:null,key:null,layoutTemplate:"<ul>{entries}</ul>",entryTemplate:'<li><a href="{url}">[{author}@{date}] {title}</a><br/>{shortBodyPlain}</li>',tokens:{},outputMode:"json",dateFormat:"dddd MMM Do",dateLocale:"en",effect:"show",offsetStart:!1,offsetEnd:!1,error:function(){console.log("jQuery RSS: url doesn't link to RSS-Feed")},onData:function(){},
|
| |
- success:function(){}},c||{});this.callback=f||this.options.success};e.htmlTags="doctype,html,head,title,base,link,meta,style,script,noscript,body,article,nav,aside,section,header,footer,h1-h6,hgroup,address,p,hr,pre,blockquote,ol,ul,li,dl,dt,dd,figure,figcaption,div,table,caption,thead,tbody,tfoot,tr,th,td,col,colgroup,form,fieldset,legend,label,input,button,select,datalist,optgroup,option,textarea,keygen,output,progress,meter,details,summary,command,menu,del,ins,img,iframe,embed,object,param,video,audio,source,canvas,track,map,area,a,em,strong,i,b,u,s,small,abbr,q,cite,dfn,sub,sup,time,code,kbd,samp,var,mark,bdi,bdo,ruby,rt,rp,span,br,wbr".split(",");
|
| |
- delete b.entries;this.feedTokens=b}return d.extend({feed:this.feedTokens,url:a.link,author:a.author,date:this.getFormattedDate(a.publishedDate),title:a.title,body:a.content,shortBody:a.contentSnippet,bodyPlain:function(a){for(var a=a.content.replace(/<script[\\r\\\s\S]*<\/script>/mgi,"").replace(/<\/?[^>]+>/gi,""),b=0;b<e.htmlTags.length;b++)a=a.replace(RegExp("<"+e.htmlTags[b],"gi"),"");return a}(a),shortBodyPlain:a.contentSnippet.replace(/<\/?[^>]+>/gi,""),index:d.inArray(a,this.entries),totalEntries:this.entries.length,
|
jquery.rss.js. Recently we detected the content was not any longer
visible and checking the script found it was consuming an external
site (http://www.feedrapp.info/) that is currently out of service. As
consequence the "Around CentOS" section in the homepage shows no
information.
This update converts the file "assets/planet.rss" into
"_data/centos/planet.yml" and updates the section code to read this
file instead. The jquery.rss.js file was removed and the approach it
provides no longer considered. So to prevent this from happening
again.
A future commit must remove the planet.yml provided in this commit, so
another one, automatically generated take its place. This way updates
from planet can be visible in the home page.
For the RSS to YAML conversion used the following python script:
import xmlplain
# Read to plain object
with open("assets/planet.rss") as inf:
root = xmlplain.xml_to_obj(inf, strip_space=True, fold_dict=True)
# Output plain YAML
with open("_data/centos/planet.yml", "w") as outf:
xmlplain.obj_to_yaml(root, outf)