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 os | |
import time | |
document = open("My Clippings.txt","r") | |
data = "".join(document.readlines()) | |
notes = [] | |
try: | |
clippings = data.split('==========') |
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
#include <SPI.h> | |
#include <Ethernet.h> | |
int min = 0; | |
int max = 255; | |
void setup(){ | |
} | |
void loop(){ | |
byte mac[] = {random(min, max), random(min, max), random(min, max), random(min, max), random(min, max), random(min, max) }; |
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/bash | |
# | |
# This script will make a webcam snapshot every commit. The jpg file will have | |
# the commit id as the filename. | |
# | |
# This script requires imagesnap. Install with: 'brew install imagesnap' | |
# | |
# Put this file in the '.git/hooks/' name it 'post-commit' and chmod it by: | |
# 'chmod +x .git/hooks/post-commit' | |
# |
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 os, markdown2, fnmatch # dependant on python-markdown2 | |
tmp = open("template.html","r").read() # HTML document with {{content}} tag | |
def locate(pattern, root=os.curdir): | |
'''Locate all files matching supplied filename pattern in and below | |
supplied root directory.''' | |
for path, dirs, files in os.walk(os.path.abspath(root)): | |
for filename in fnmatch.filter(files, pattern): | |
yield os.path.join(path, filename) |
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
for i in $(seq 13); do wget "http://www.minimovies.org/video/ILoveAlaska/Episode_$i.flv"; done | |
for i in $(seq 13); do ffmpeg -i "Episode_$i.flv" -acodec copy "text_$i.mp3"; done |
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
$$ = "hot fix" | |
__ = "push zone" | |
fixme = [ | |
[ 00, 00, 01, 02, 02, 02 ], | |
[ 03, 00, 01, 04, 05, 05 ], | |
[ 03, $$, $$, 04, 00, 00 , __, __], | |
[ 00, 05, 00, 04, 06, 06 ], | |
[ 07, 05, 08, 08, 00, 00 ], | |
[ 07, 09, 09, 09, 00, 00 ] |
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
// Dependencies: eHealth, Mozzi. | |
#include <eHealth.h> | |
float ECG = 0; | |
int ECGfreq = 100; | |
unsigned long lastsampleECG = 0; | |
unsigned long time = 0; | |
#include <MozziGuts.h> | |
#include <ReverbTank.h> |
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
require 'formula' | |
class Awesome < Formula | |
url 'http://awesome.naquadah.org/download/awesome-3.4.10.tar.bz2' | |
homepage 'http://awesome.naquadah.org/' | |
md5 '245087f8065867eff37a2133287d5c03' | |
depends_on 'cmake' | |
depends_on 'lua' | |
depends_on 'imlib2' |
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
var url = 'https://twitter.com/jellea/followers/users?include_available_features=0&include_entities=1'; | |
var list = ''; | |
var request = function(cursor){ | |
var curs = '&cursor='+cursor; | |
$.getJSON(url+curs,function(data){ | |
list+=data.items_html; | |
if(data.has_more_items){ | |
request(data.cursor); | |
} | |
}); |
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 | |
# PROVIDE: forever | |
# REQUIRE: NETWORKING SERVERS DAEMON | |
# BEFORE: LOGIN | |
# KEYWORD: shutdown | |
# Taken from http://habrahabr.ru/post/137857/ | |
. /etc/rc.subr |
OlderNewer