This file contains 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
# wget http://python-twitter.googlecode.com/svn-history/r151/branches/hameedullah/twitter.py -O twitterwithsearch.py | |
import twitterwithsearch as twitter | |
done = [] | |
testfile = open('spammers.txt', 'U') | |
for p in testfile: | |
done.append(p.rstrip()) | |
username = '' | |
password = '' | |
ts = twitter.Api(username=username, password=password) | |
aq = ts.Search("CTX Mortgage reportedly for sale",rpp=50) |
This file contains 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
/* | |
* TV Timer by Harrison Conlin | |
* http://harrisony.com/tvtimer.html | |
* | |
*/ | |
#include <LiquidCrystal.h>; | |
#define BTN2 (15) | |
#define POT (3) | |
#define PIEZO (9) |
This file contains 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
import tweepy | |
username = 'hugsbot' | |
password = 'secret' | |
api = tweepy.API(tweepy.BasicAuthHandler(username,password)) | |
def givehugs(): | |
for follower in tweepy.Cursor(api.followers).items(): | |
print follower.screen_name | |
api.update_status('@%s Hi, this is your daily hug *hug*' % follower.screen_name) | |
hugssince = 0 | |
def searchhugs(): |
This file contains 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
Module ImplicitLineContinuations | |
'After a comma (,). | |
Public Function test1(ByVal x As Integer, | |
ByVal y As Object, ByVal z As Object) | |
Return 1 | |
End Function | |
'After an open parenthesis (() or before a closing parenthesis ()). | |
Public Function test2( | |
ByVal x As Integer, ByVal y As Object, ByVal z As Object | |
) |
This file contains 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
void list_generator(int (*process)(Record, string[]), string options[], string success, string failure){ | |
bool _recordcount = 0; | |
Record processing[recordcount]; | |
for (int i=0; i <= recordcount; i++){ | |
if ((*process)(records[i], options) > 0){ | |
processing[++_recordcount] = records[i]; | |
} | |
} | |
if (_recordcount > 0){ | |
cout << success; |
This file contains 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
--- Utilities.php.orig 2013-01-17 13:50:22.892638237 +1100 | |
+++ Utilities.php 2013-01-17 13:49:42.712169200 +1100 | |
@@ -355,7 +355,7 @@ | |
/* We use a very strict regex to parse the timestamp. */ | |
if(preg_match('/^(\\d\\d\\d\\d)-(\\d\\d)-(\\d\\d)' . | |
- 'T(\\d\\d):(\\d\\d):(\\d\\d)(?:\\.\\d+)?$/D', | |
+ 'T(\\d\\d):(\\d\\d):(\\d\\d)(?:\\.\\d+)?(Z)?$/D', | |
$time, $matches) == 0) { | |
throw new Exception( |
This file contains 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 | |
find $1 -mindepth 1 -maxdepth 1 -type d | while read -r dir | |
do | |
pushd "$dir" | |
echo $dir | |
if [[ -d ".git" ]]; then | |
git pull | |
fi | |
if [[ -d ".hg" ]]; then | |
hg pull |
This file contains 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 | |
wget -q -O - "http://downforeveryoneorjustme.com/$1" | grep -E '.*class="domain"' | sed 's/<a href.*>\(.*\)<\/a>/\1/' | sed 's/<\/span>//' |
This file contains 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 | |
# Alot of these configs have been taken from the various places | |
# on the web, most from here | |
# https://github.com/mathiasbynens/dotfiles/blob/master/.osx | |
# Set the colours you can use | |
black='\033[0;30m' | |
white='\033[0;37m' | |
red='\033[0;31m' |
This file contains 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 | |
# ReadingListCatcher | |
# - A script for exporting Safari Reading List items to Markdown and Pinboard | |
# Brett Terpstra 2015 | |
# Uses code from <https://gist.github.com/robmathers/5995026> | |
# Requires Python pinboard lib for Pinboard.in import: | |
# `easy_install pinboard` or `pip install pinboard` | |
import plistlib | |
from shutil import copy | |
import subprocess |
OlderNewer