start new:
tmux
start new with session name:
tmux new -s myname
Latency Comparison Numbers (~2012) | |
---------------------------------- | |
L1 cache reference 0.5 ns | |
Branch mispredict 5 ns | |
L2 cache reference 7 ns 14x L1 cache | |
Mutex lock/unlock 25 ns | |
Main memory reference 100 ns 20x L2 cache, 200x L1 cache | |
Compress 1K bytes with Zippy 3,000 ns 3 us | |
Send 1K bytes over 1 Gbps network 10,000 ns 10 us | |
Read 4K randomly from SSD* 150,000 ns 150 us ~1GB/sec SSD |
export PATH="$HOME/.rbenv/bin:/usr/local/bin:$PATH" | |
eval "$(rbenv init -)" |
#!/usr/bin/env sh | |
## | |
# This is script with usefull tips taken from: | |
# https://github.com/mathiasbynens/dotfiles/blob/master/.osx | |
# | |
# install it: | |
# curl -sL https://raw.github.com/gist/2261461/hack.sh | sh | |
# |
var express = require('express'); | |
var sys = require('util'); | |
var oauth = require('oauth'); | |
var app = express.createServer(); | |
var _twitterConsumerKey = process.env['TWITTER_CONSUMER_KEY']; | |
var _twitterConsumerSecret = process.env['TWITTER_CONSUMER_SECRET']; | |
console.log("_twitterConsumerKey: %s and _twitterConsumerSecret %s", process.env['TWITTER_CONSUMER_KEY'], process.env['TWITTER_CONSUMER_SECRET']); |
brew update | |
brew versions FORMULA | |
cd `brew --prefix` | |
git checkout HASH Library/Formula/FORMULA.rb # use output of "brew versions" | |
brew install FORMULA | |
brew switch FORMULA VERSION | |
git checkout -- Library/Formula/FORMULA.rb # reset formula | |
## Example: Using Subversion 1.6.17 | |
# |
;; outlet code for implementing traditional macro expansion | |
;; macros | |
(define (expand form) | |
(cond | |
((variable? form) form) | |
((literal? form) form) | |
((macro? (car form)) | |
(expand ((macro-function (car form)) form))) |
Get Homebrew installed on your mac if you don't already have it
Install highlight. "brew install highlight". (This brings down Lua and Boost as well)
require 'test_helper' | |
shared_examples_for 'An Adapter' do | |
describe '#read' do | |
before do | |
@adapter.write(@key = 'whiskey', @value = "Jameson's") | |
end | |
it 'reads a given key' do | |
@adapter.read(@key).must_equal(@value) |
kvz: "I'm recommending these Mac apps to a colleague who's losing his OSX virginity: https://gist.github.com/1372883. Anything you think I should add?"
Don't forget to look at the suggestions at the bottom, there's some cool stuff in there.