This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ruby-1.9.2-p0 > require 'postrank-api' | |
| ruby-1.9.2-p0 > pr = PostRank::API.new('ig') | |
| ruby-1.9.2-p0 > pr.feed(pr.feed_info('igvita.com')['id'], :num => 5)['items'].map {|i| i['content'].gsub(/<\/?[^>]*>/, "").summarize} | |
| [ | |
| [0] "The world of concurrent computation is a complicated one. Hence, not surprisingly, when Bruce Tate asked Matz, in an interview for his recent book (Seven Languages in Seven Weeks) for a feature that he would like to change in Ruby if he could go back in time, the answer was telling: \xE2\x80\x9CI would remove the thread and add actors or some other more advanced concurrency features\xE2\x80\x9D.\nProcess Calculi & Advanced Concurrency\nIt is easy to read a lot into Matz's statement, but the follow-up question is: more advanced concurrency features? Process calculi is the formal name for the study of many related approaches of modeling the behavior of concurrent systems, which provides many alternatives: CCS, CSP, ACP, and Actor models just to name a few.\nActors, CSP and Pi-calculus\n |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| javascript:function%20iprl5(){var%20d=document,z=d.createElement('scr'+'ipt'),b=d.body;try{if(!b)throw(0);d.title='(Saving...)%20'+d.title;z.setAttribute('src','http://www.instapaper.com/j/instapaper_uniqueID?u='+encodeURIComponent(d.location.href)+'&t='+(new%20Date().getTime()));b.appendChild(z);}catch(e){alert('Please%20wait%20until%20the%20page%20has%20loaded.');}}iprl5();void(0);javascript:function%20iprl6(){var%20d=document,z=d.createElement('scrip'+'t'),b=d.body,l=d.location;try{if(!b)throw(0);z.setAttribute('src',l.protocol+'//knowabout.it/j/b.js');b.appendChild(z);}catch(e){alert('Please%20wait%20until%20the%20page%20has%20loaded.');}}iprl6();kai_user='knowaboutit_userID';void(0); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/sh | |
| # Chromium update script | |
| # - by shad <[email protected]> | |
| # mac | linux | ... | |
| OS=mac | |
| LATEST=$(curl http://build.chromium.org/f/chromium/snapshots/chromium-rel-${OS}/LATEST) | |
| echo latest build ${LATEST} | |
| INSTALL_DIR=/Applications | |
| TMP="/tmp/update-chrome-$RANDOM" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <a href="javascript:(function(){var s1=window.document.createElement('script');s1.setAttribute('src','http://ajax.googleapis.com/ajax/libs/jquery/1.4.4/jquery.min.js');window.document.body.appendChild(s1);var s2=window.document.createElement('script');s2.setAttribute('src','http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.7/jquery-ui.min.js');window.document.body.appendChild(s2);s1.onload=s1.onreadystatechange=function(){if(!this.readyState||this.readyState=='loaded'||this.readyState=='complete'){s2.onload=s2.onreadystatechange=function(){if(!this.readyState||this.readyState=='loaded'||this.readyState=='complete'){$('div').draggable();$('div').resizable();$('div').css({'border-style':'dashed','border-width':'3px','border-color':'black','background':'#00ccFF'});}};}};})();">CC</a> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $(document).ready(function(){ | |
| $(".run").click(function(){ | |
| $("#box").animate({opacity: "0.1", left: "+=400"}, 1200) | |
| .animate({opacity: "0.4", top: "+=160", height: "20", width: "20"}, "slow") | |
| .animate({opacity: "1", left: "0", height: "100", width: "100"}, "slow") | |
| .animate({top: "0"}, "fast") | |
| .slideUp() | |
| .slideDown("slow") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var lyrics = [ | |
| {line : 1, words : "I'm a lumberjack and I'm okay"}, | |
| {line : 2, words : "I sleep all night and I work all day"}, | |
| {line : 3, words : "He's a lumberjack and he's okay"}, | |
| {line : 4, words : "He sleeps all night and he works all day"} | |
| ]; | |
| _(lyrics).chain() | |
| .map(function(line) { return line.words.split(' '); }) | |
| .flatten() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function GetMatchingStatuses(buildString) { | |
| var twitterapiurl = "http://search.twitter.com/search.json?since_id=" + lastID + "&q=" + buildString + "&rpp=100&callback=?"; | |
| show("GetMatchingStatuses apiurl " + twitterapiurl, 'info-console'); | |
| $.getJSON(twitterapiurl, function(ob) { | |
| FormatTweets(ob); | |
| }); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| email: function (val) { | |
| return /^((([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+)*)|((\x22)((((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(([\x01-\x08\x0b\x0c\x0e-\x1f\x7f]|\x21|[\x23-\x5b]|[\x5d-\x7e]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(\\([\x01-\x09\x0b\x0c\x0d-\x7f]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))))*(((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(\x22)))@((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?$/i.test(val); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| console.log(message.toString()); | |
| socket.on("listening",function(){ | |
| console.log("sending"); | |
| socket.send(message, 0, message.length, 42424, "telehash.org", function(){ setTimeout(process.exit,1000); }); | |
| }); | |
| socket.bind(34344); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| try { | |
| data = fs.readFileSync('./keys','ascii') | |
| keys = JSON.parse(data); | |
| } catch(e) { | |
| console.log(e); | |
| keys = ezcrypto.generateKey(); | |
| fs.writeFileSync('./keys',JSON.stringify(keys)); | |
| } | |
| var socket = dgram.createSocket("udp4"); |