Skip to content

Instantly share code, notes, and snippets.

fall distance = dx above bolt * 2 + excess rope
excess rope = dx you to bolt * 2
fall distance = dx above bolt * 2 + dx you to bolt * 2
dx above bolt = (distance between bolts - dx you to bolt)
dx you to bolt = (distance between bolts - dx above bolt)
— no reachy
dx you to bolt = 0
fall distance = dx above bolt * 2
fall distance = 2 * (distance between bolts - dx you to bolt)
" vimrc.before
let mapleader = ","
" turn off all the gui crap
set guioptions=aAce
" nicer auto complete menus
set completeopt=longest,menuone
#!/usr/bin/expect
spawn python3.2 [lindex $argv 0]
expect "mail"
send beaufabry@gmail.com\r
expect "assword"
send ASSSSSSSSS\r
interact
module DataSource
module ConnectionProxies
class TeradataConnectionProxy < ConnectionProxy
def initialize(connection)
super(connection)
connection.class_eval do
@connection.class_eval do
def columns(*args)
binding.pry
(defproject going-native "0.1.0-SNAPSHOT"
:description "FIXME: write description"
:url "http://example.com/FIXME"
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:jvm-opts ["-Djava.library.path=/usr/share/java"]
:main going-native.core
:dependencies [[org.clojure/clojure "1.5.1"]
[net.java.dev.jna/jna "3.3.0"]])
(ns going-native.core
(:import (com.sun.jna "Native"))
(:gen-class))
(gen-interface
:name jna.CLibrary
:extends [com.sun.jna.Library]
:methods [[printf [String] Integer]])
(def glibc (Native/loadLibrary "c" jna.CLibrary))
class ComposedCache
def initialize(target)
@target = target
end
def cache(*method_names)
method_names.each do |m|
original = @target.method(m)
results = {}
class Memoizer
def initialize(tgt)
@target = tgt
@cache = {}
end
def cache(*method_names)
method_names.each {|name| cache[name] = {} }
end
(ns predict-train-delays.twitter
(:use
[twitter.oauth]
[twitter.callbacks]
[twitter.callbacks.handlers]
[twitter.api.restful])
(:import
(twitter.callbacks.protocols SyncSingleCallback)))
(def my-creds (make-oauth-creds "nkjAm6lD6tpMwE6UeFw"
#!/bin/bash
#xrdb -merge .Xresources
trayer --edge top --align right --SetDockType true --SetPartialStrut true --expand true --width 15 --height 12 --transparent true --tint 0x000000 &
gnome-screensaver &