Skip to content

Instantly share code, notes, and snippets.

View textarcana's full-sized avatar

Noah Sussman textarcana

View GitHub Profile
#!/usr/bin/env python
"""
Create SPC charts from data sets. Inspired by Simon Guilfoyle's
"Intelligent Policing" http://amzn.to/1dNNCfb
The algorithm described by Guilfoyle in the book is:
Given a list of data points sorted in chronological order, iterate
over the list starting at index 1 (that is, skip the last entry in
the list), subtracting each value from the previous value. The
<iframe src="http://www.slideshare.net/slideshow/embed_code/11846374?rel=0" width="427" height="356" frameborder="0" marginwidth="0" marginheight="0" scrolling="no" style="border:1px solid #CCC; border-width:1px 1px 0; margin-bottom:5px; max-width: 100%;" allowfullscreen> </iframe> <div style="margin-bottom:5px"> <strong> <a href="https://www.slideshare.net/noahsussman/software-entomology-or-where-do-bugs-come-from" title="Software Entomology or Where Do Bugs Come From?" target="_blank">Software Entomology or Where Do Bugs Come From?</a> </strong> from <strong><a href="http://www.slideshare.net/noahsussman" target="_blank">Noah Sussman</a></strong> </div>
@textarcana
textarcana / test-runner.sh
Created July 23, 2014 19:41
A simple test runner in bash and Perl.
perl -lwne 'BEGIN{$status=0;
print "tests running..."};
print qq{$_:};
$result = qx{curl -s -IL $_ | grep "200 OK"};
if ($result eq ""){print "FAIL\n"; $status=1} else {print $result};
END{if($status != 0){print "Some tests failed."} else {print "All done!"};
exit $status}' test.config
@textarcana
textarcana / README
Created October 2, 2014 16:15
A Web log data set from The Web Server Workload Characterization project. ftp://ita.ee.lbl.gov/html/contrib/NASA-HTTP.html
A Web log data set from The Web Server Workload Characterization project. ftp://ita.ee.lbl.gov/html/contrib/NASA-HTTP.html
@textarcana
textarcana / gist:2a9f8bf46a509a814732
Created January 20, 2015 17:03
sparkler coverage reported by constants.py
Name Stmts Miss Cover
--------------------------------------------------------------------------------------------------------------------------------
/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/dateutil/__init__ 3 0 100%
/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/dateutil/parser 611 527 14%
/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/dateutil/relativedelta 221 192 13%
/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/dateutil/rrule 815 720 12%
/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/dateutil/tz 575 476 17%
/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/dateutil/tzwin 106 103
@textarcana
textarcana / index.html
Last active August 29, 2015 14:21 — forked from biovisualize/index.html
d3 Game of Life / cellular automaton
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title></title>
<script type='text/javascript' src="http://mbostock.github.com/d3/d3.js"></script>
<style type='text/css'>
.cell{
stroke: none;
}
@textarcana
textarcana / Freenode Account Setup
Created February 13, 2009 15:52
Freenode registration
== Example
/nick homer
/msg nickserv register changeme beerdude@example.com
/nick homer_
/msg nickserv group
/nick awesome_homer
/msg nickserv group
@textarcana
textarcana / .emacs
Created February 14, 2009 22:06
.emacs file for Aquamacs Emacs and GNU Emacs on OS X.
;;Noah Sussman's .emacs file for Aquamacs Emacs and GNU Emacs on OS X.
;;Branched February 16 2008 from my config for GNU Emacs for Windows, created Oct 18 2001.
;;Time-stamp: </Users/noah/Documents/n_s/config/emacs/aquamacs/.emacs last changed by Noah Sussman on noah.local/Textarcana Saturday 14 February 2009 at EST 16:51:25>
(load-file "~/.emacs-cfg/secrets.el")
;;;; Spaces are always used for indendation
;;;;;; Haml and Sass modes require this setting
(setq indent-tabs-mode nil)
@textarcana
textarcana / equal_height_columns.js
Created February 20, 2009 22:35
One way to ensure one column is the same height as another. Extra complex because I am using 'sliding doors' drop shadow on the columns. Appears to work in FF, IE, Opera, Chrome and Webkit but ymmv.
/**
* Equal height column hack for Favorites box
*/
var fudgeAmt = (document.all === null ? 47 : 27);
var heightToMatch = $('equalHeightColumnsHack').clientHeight - fudgeAmt;
var shadowHeight = heightToMatch + 24;
var elems = {};
elems.container = $$('#featured .content')[0];
elems.shadow = $$('#featured .content .dropShadowHack')[0];
/* Prettified the getComputedStyle wrapper a bit over what's in the repo, see http://www.quirksmode.org/dom/getstyles.html */
@textarcana
textarcana / ECB_Installation_and_Configuration_for_Macports_1.7.el
Created February 23, 2009 18:40
Install and configure ECB (the Emacs Code Browser) and its dependencies, on Macports 1.7
;; Emacs Code Browser
;; On Macports 1.7 it appears ECB can't install because it looks for speedbar as a dependency, but that port isnt available as its been rolled into cedet-devel.
;; So with 1.7, I did the following (which appears to work):
;; sudo port install cedet-devel
;; wget http://downloads.sourceforge.net/ecb/ecb-2.32.tar.gz
;; open ecb-2.32.tar.gz
;; mv ecb-2.32 ecb
;; sudo mv ecb /usr/share/emacs/site-lisp/
(load-file "/opt/local/var/macports/software/cedet-devel/1.0pre4_0/opt/local/share/emacs/site-lisp/common/cedet.el")