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
| #!/usr/bin/env python | |
| from pyquery import PyQuery as pq | |
| import urllib2 | |
| from datetime import datetime | |
| from dateutil.parser import parse | |
| import PyRSS2Gen as rss | |
| from pytz import timezone | |
| import re | |
| import sys |
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
| from pyquery import PyQuery as pq | |
| import urllib2 | |
| from datetime import datetime | |
| import PyRSS2Gen as rss | |
| d = pq(url='http://www.ssc.wisc.edu/~wright/Sociology-125-podcasts-2012.htm') | |
| URL_ROOT = 'http://www.ssc.wisc.edu/~wright/' | |
| items = [] |
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
| hardstatus on | |
| hardstatus alwayslastline | |
| startup_message off | |
| termcapinfo xterm ti@:te@ | |
| hardstatus string "%{= kG}%-w%{.rW}%n %t%{-}%+w %=%{..G} %H %{..Y} %m/%d %C%a " | |
| screen -t shell 0 | |
| screen -t irc 1 | |
| screen -t code 2 | |
| screen -t etc 3 |
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 express = require('express'); | |
| var app = express(); | |
| require('./core.js')(app, {'namespace': 'api', 'api_key': 'abcdefghijklmnopqrstuvwxyz123456' }); | |
| app.listen(3000); |
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
| require "twitter" | |
| # Set sample size (pick this percentage of your followers) | |
| SAMPLE_SIZE = 0.25 | |
| # Construct Twitter instance | |
| t = Twitter.new | |
| # Add screenname to params | |
| screen_name = "zthomae" |
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
| require "twitter" | |
| require "tumblr4r" | |
| require "date" | |
| # Construct Twitter instance | |
| t = Twitter.new | |
| # Define screen_name. | |
| screen_name = "zthomae" |
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
| ## SPLIT AROUND SPACE ## | |
| import string | |
| # All forms of whitespace except the space | |
| whitespace = string.whitespace[:-1] | |
| # Split a string around its whitespace, with words and whitespace being entries in a list | |
| def split_around_space(string): | |
| new = [] |
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
| #!/usr/bin/python2.7 | |
| import pickle, os, sys | |
| from sets import Set | |
| from random import randrange | |
| from shutil import make_archive, rmtree | |
| from time import time | |
| def SetGenCount(input_length): | |
| """ |
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
| <html> | |
| <head> | |
| </head> | |
| <body> | |
| <a href="javascript:(function(e,a,g,h,f,c,b,d)%7Bif(!(f=e.jQuery)%7C%7Cg%3Ef.fn.jquery%7C%7Ch(f))%7Bc=a.createElement(%22script%22);c.type=%22text/javascript%22;c.src=%22http://ajax.googleapis.com/ajax/libs/jquery/%22+g+%22/jquery.min.js%22;c.onload=c.onreadystatechange=function()%7Bif(!b&&(!(d=this.readyState)%7C%7Cd==%22loaded%22%7C%7Cd==%22complete%22))%7Bh((f=e.jQuery).noConflict(1),b=1);f(c).remove()%7D%7D;a.documentElement.childNodes%5B0%5D.appendChild(c)%7D%7D)(window,document,%221.7.2%22,function($,L)%7Bdiv=document.getElementById(%22overlay%22).parentNode;div.removeChild(overlay);div.removeChild(gatewayCreative);document.getElementsByTagName(%22html%22)%5B0%5D.style.overflow=%22scroll%22;%7D);">Kill NYTimes Paywall</a> | |
| <a href="javascript:(function(e,a,g,h,f,c,b,d)%7Bif(!(f=e.jQuery)%7C%7Cg%3Ef.fn.jquery%7C%7Ch(f))%7Bc=a.createElement(%22script%22);c.type=%22text/javascript%22;c.src=%22http://ajax.googleapis.com/ajax/libs/jquery/%22+g+%22/jquery.min.js%22;c.onload=c.onrea |
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 fetchTweets(user) { | |
| $.ajax({ | |
| type : 'GET', | |
| dataType : 'jsonp', | |
| url : 'http://api.twitter.com/1/statuses/user_timeline.json', | |
| data : { screen_name: user, | |
| count: 200, | |
| include_rts: 1, |