-
Kinesis Freestyle (Terrible key switches. Mushy and un-lovable)
-
Kinesis Freestyle Edge (Traditional layout with too many keys, mech switches, proably too big to be tented easily/properly)
-
Matias Ergo Pro (Looks pretty great. Have not tried.)
-
ErgoDox Kit (Currently, my everyday keyboard. Can buy pre-assembled on eBay.)
-
ErgoDox EZ (Prolly the best option for most people.)
(defn get-key | |
[prefix key] | |
(if (nil? prefix) | |
key | |
(str prefix "-" key))) | |
(defn flatten-map-kvs | |
([map] (flatten-map-kvs map nil)) | |
([map prefix] | |
(reduce | |
(fn [memo [k v]] |
#!/usr/bin/perl | |
# This filter changes all words to Title Caps, and attempts to be clever | |
# about *un*capitalizing small words like a/an/the in the input. | |
# | |
# The list of "small words" which are not capped comes from | |
# the New York Times Manual of Style, plus 'vs' and 'v'. | |
# | |
# 10 May 2008 | |
# Original version by John Gruber: |
(defmacro with-system-out-str | |
[& body] | |
`(let [out# System/out | |
buf# (java.io.ByteArrayOutputStream.) | |
prs# (java.io.PrintStream. buf#) | |
wtr# (java.io.OutputStreamWriter. prs#)] | |
(try | |
(System/setOut prs#) | |
(binding [*out* wtr#] | |
(do ~@body)) |
#!/bin/sh | |
if [ "$#" -eq 1 ]; then stdinmsg=$(cat); fi | |
exec <"$0" || exit; read v; read v; read v; exec /usr/bin/osascript - "$@" "$stdinmsg"; exit | |
-- another way of waiting until an app is running | |
on waitUntilRunning(appname, delaytime) | |
repeat until my appIsRunning(appname) | |
tell application "Messages" to close window 1 | |
delay delaytime | |
end repeat |
This simple script will take a picture of a whiteboard and use parts of the ImageMagick library with sane defaults to clean it up tremendously.
The script is here:
#!/bin/bash
convert "$1" -morphology Convolve DoG:15,100,0 -negate -normalize -blur 0x1 -channel RBG -level 60%,91%,0.1 "$2"
Since many deployments may start out with 3 nodes and so little is known about how to grow a cluster from 3 memebrs to 5 members without losing the existing Quorum, here is an example of how this might be achieved.
In this example, all 5 nodes will be running on the same Vagrant host for the purpose of illustration, running on distinct configurations (ports and data directories) without the actual load of clients.
YMMV. Caveat usufructuarius.
#Overview drip is an awesome command line tool that can be used to dramatically lower perceived JVM startup time. It does this by preloading an entirely new JVM process\instance and allowing you to simply use the preloaded environment. This has extraordinary results with jruby.
We reduced time to run rake environment
from 13 seconds to a mere 3.5 seconds. This is actually at or near MRI 1.9.3p327 (with falcon patch) speeds!
Adding a few addition jruby options will reduce startup time even further (down to 1.69 seconds).
#Install Drip Install drip if you haven't already (see https://github.com/flatland/drip)
(defn get-clipboard [] | |
(.getSystemClipboard (java.awt.Toolkit/getDefaultToolkit))) | |
(defn slurp-clipboard [] | |
(try | |
(.getTransferData (.getContents (get-clipboard) nil) (java.awt.datatransfer.DataFlavor/stringFlavor)) | |
(catch java.lang.NullPointerException e nil))) | |
(defn spit-clipboard [text] | |
(.setContents (get-clipboard) (java.awt.datatransfer.StringSelection. text) nil)) |