Skip to content

Instantly share code, notes, and snippets.

Keybase proof

I hereby claim:

  • I am toby on github.
  • I am toby (https://keybase.io/toby) on keybase.
  • I have a public key whose fingerprint is 8322 D2CE 33FD F3A8 475E 0A85 7011 E469 37DA CC15

To claim this, I am signing this object:

@toby
toby / mkjava.sh
Created August 19, 2013 01:04
Ubuntu Oracle Java Install
echo oracle-java7-installer shared/accepted-oracle-license-v1-1 select true | /usr/bin/debconf-set-selections
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys EEA14886
echo "deb http://ppa.launchpad.net/webupd8team/java/ubuntu quantal main" >> /etc/apt/sources.list
echo "deb-src http://ppa.launchpad.net/webupd8team/java/ubuntu quantal main" >> /etc/apt/sources.list
apt-get update
apt-get -y install oracle-java7-installer
apt-get -y install oracle-java7-set-default
arkanoid:~ toby$ ping www.google.com
PING www.google.com (74.125.131.106): 56 data bytes
64 bytes from 74.125.131.106: icmp_seq=0 ttl=45 time=32.454 ms
Request timeout for icmp_seq 1
Request timeout for icmp_seq 2
64 bytes from 74.125.131.106: icmp_seq=3 ttl=45 time=38.050 ms
Request timeout for icmp_seq 4
Request timeout for icmp_seq 5
Request timeout for icmp_seq 6
64 bytes from 74.125.131.106: icmp_seq=7 ttl=45 time=33.073 ms
@toby
toby / gist:3783867
Created September 25, 2012 19:18
Lazy select with Korma
(ns something.cool
(:use [korma.core]))
(def page-size 20)
(defn lazy-select
"Creates a lazy sequence of sql results by batch selecting."
([statement]
(lazy-select statement 0))
([statement o]