Skip to content

Instantly share code, notes, and snippets.

Avatar

Ted Timmons tedder

View GitHub Profile
@tedder
tedder / Questions
Created Jul 11, 2011
Magma Rails Give-away
View Questions
Day Job:
Open Source contribution (if any):
Tell me about your experience with Ruby/Rails:
How do you use GitHub:
Favorite luchador(es):
View gist:1502908
dependent variable: acachesize
Df Sum Sq Mean Sq F value Pr(>F)
aepochtime 1 5.3833e+08 5.3833e+08 140.0642 < 2.2e-16 ***
adrops 1 1.2991e+05 1.2991e+05 0.0338 0.854140
amemory 1 1.3598e+10 1.3598e+10 3538.0387 < 2.2e-16 ***
aepochtime:adrops 1 6.7696e+07 6.7696e+07 17.6133 2.76e-05 ***
aepochtime:amemory 1 2.9061e+07 2.9061e+07 7.5612 0.005988 **
adrops:amemory 1 1.9934e+07 1.9934e+07 5.1865 0.022811 *
aepochtime:adrops:amemory 1 2.7078e+07 2.7078e+07 7.0452 0.007977 **
@tedder
tedder / smugup.sh
Created Jan 26, 2012
smugmug uploader script, from the (dead site) braindump.dk.
View smugup.sh
#!/bin/sh
which curl > /dev/null
test $? -gt 0 && echo "Curl is not on the path" && exit 1
test -f ~/.smugup && source ~/.smugup
UA="smugup.sh/1.0 (recht@braindump.dk)"
APIKEY="yppE0KMFXm9YwpJHXrrKR5MAHoWZvVaH"
View gist:1719005
From New Scientist, but subscription only, so providing here:
Self-controlled people have better lives – but for the rest, lack of willpower is more like physical fatigue than moral failure
AS THE last of your New Year's resolutions unravels in front of your eyes, you probably feel like a moral pygmy. But before you sink into a heap of self-loathing, consider this.
After decades of research, psychologists now reckon two traits are most likely to make us successful. The first is intelligence, with smart people doing better at all jobs. Unluckily, there is little evidence that you can make lasting improvements to intelligence.
View s3-list-all-files-in-all-buckets.py
import boto
s3 = boto.connect_s3("key", "secret")
for bucket in s3.get_all_buckets():
if not bucket.name.islower():
print "-- skipping bucket, cannot handle uppercase bucket names: " + bucket.name
continue
for file in bucket:
print "\t\t" + str(file.size) + "\t" + file.name
View gist:3688572
package net.inervo;
import java.io.File;
import java.io.FileNotFoundException;
import java.io.FilenameFilter;
import java.io.StringWriter;
import org.apache.commons.io.IOUtils;
import com.amazonaws.AmazonClientException;
View gist:4365981
{"0": 1, "640": 1, "130": 58, "260": 67, "390": 27, "520": 2, "10": 3, "140": 70, "270": 56, "400": 17, "530": 8, "20": 20, "150": 66, "280": 63, "410": 13, "540": 2, "30": 20, "160": 64, "290": 50, "420": 18, "550": 2, "40": 33, "170": 75, "300": 38, "430": 13, "560": 2, "50": 25, "180": 73, "310": 45, "440": 17, "570": 3, "60": 18, "190": 72, "320": 30, "450": 6, "580": 1, "70": 49, "200": 59, "330": 42, "460": 9, "590": 2, "80": 59, "210": 63, "340": 20, "470": 10, "600": 1, "90": 49, "220": 55, "350": 31, "480": 9, "100": 55, "230": 67, "360": 26, "490": 9, "620": 1, "110": 62, "240": 69, "370": 23, "500": 11, "120": 65, "250": 50, "380": 19, "510": 5}
@tedder
tedder / gist:4366001
Created Dec 23, 2012
ascii histogram
View gist:4366001
0 *
10 ***
20 ********************
30 ********************
40 *********************************
50 *************************
60 ******************
70 *************************************************
80 ***********************************************************
90 *************************************************
@tedder
tedder / gist:8203137
Created Dec 31, 2013
mlkshk top images of 2013 html generatomagic script
View gist:8203137
import requests
hotlist = requests.get('http://mlkshk.com/static/outfile.txt').text
count = 0
for line in hotlist.splitlines():
share_key, created, like_count, username = line.split("\t")
count += 1
if share_key == 'share_key': continue
print """
<div class="theimage"><a href="http://mlkshk.com/p/%s"><img src="http://s.mlkshk.com/r/%s" border=0 width="500"></a>
View gist:9799586
### Keybase proof
I hereby claim:
* I am tedder on github.
* I am tedder42 (https://keybase.io/tedder42) on keybase.
* I have a public key whose fingerprint is F7B5 7051 77AD F15D 39E0 BE29 CF4D 3C41 DAEF 5557
To claim this, I am signing this object:
You can’t perform that action at this time.