A ZSH theme optimized for people who use:
- Solarized
- Git
- Unicode-compatible fonts and terminals (I use iTerm2 + Menlo)
For Mac users, I highly recommend iTerm 2 + Solarized Dark
| /* | |
| * object.watch polyfill | |
| * | |
| * 2012-04-03 | |
| * | |
| * By Eli Grey, http://eligrey.com | |
| * Public Domain. | |
| * NO WARRANTY EXPRESSED OR IMPLIED. USE AT YOUR OWN RISK. | |
| */ |
| var express = require('express'), | |
| request = require('request'), | |
| BufferList = require('bufferlist').BufferList, | |
| sys = require('sys'); | |
| var app = express.createServer( | |
| express.logger(), | |
| express.bodyDecoder() | |
| ); |
| var vm = require('vm'), | |
| code = 'var square = n * n;', | |
| fn = new Function('n', code), | |
| script = vm.createScript(code), | |
| sandbox; | |
| n = 5; | |
| sandbox = { n: n }; | |
| benchmark = function(title, funk) { |
| express = require("express") | |
| request = require("request") | |
| BufferList = require("bufferlist").BufferList | |
| app = express.createServer(express.logger(), express.bodyParser()) | |
| app.get "/", (req, res) -> | |
| if req.param("url") | |
| url = unescape(req.param("url")) | |
| request | |
| uri: url | |
| encoding: 'binary' |
| Highcharts.Chart.prototype.callbacks.push(function(chart) { | |
| var hasTouch = hasTouch = document.documentElement.ontouchstart !== undefined, | |
| mouseTracker = chart.tracker, | |
| container = chart.container, | |
| mouseMove; | |
| mouseMove = function (e) { | |
| // let the system handle multitouch operations like two finger scroll | |
| // and pinching | |
| if (e && e.touches && e.touches.length > 1) { |
| #!/bin/bash | |
| # bash generate random alphanumeric string | |
| # | |
| # bash generate random 32 character alphanumeric string (upper and lowercase) and | |
| NEW_UUID=$(cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1) | |
| # bash generate random 32 character alphanumeric string (lowercase only) | |
| cat /dev/urandom | tr -dc 'a-z0-9' | fold -w 32 | head -n 1 |
| /* ---------------------------------------------------------- */ | |
| /* */ | |
| /* A media query that captures: */ | |
| /* */ | |
| /* - Retina iOS devices */ | |
| /* - Retina Macs running Safari */ | |
| /* - High DPI Windows PCs running IE 8 and above */ | |
| /* - Low DPI Windows PCs running IE, zoomed in */ | |
| /* - Low DPI Windows PCs and Macs running Firefox, zoomed in */ | |
| /* - Android hdpi devices and above */ |
| #!/bin/bash | |
| # Uses Day One cli [http://dayoneapp.com/tools/cli-man] and sqlite3 | |
| # Expects extract from iPhone backup made by JuicePhone [http://www.addpod.com/juicephone], folder with a device name should be passed as an argument | |
| [ -z "$1" ] && echo "$0: Usage: $0 Device-Name-Exctracted-Folder" && exit 0 | |
| [ ! -d "$1" ] && echo "$0: $1 is not a directory" && exit 0 | |
| [ ! -e "$1/Application Data/Raconteur/Documents/Entries.sqlite" ] && echo "$0: $1 doesn't contain Racounter app extract." && exit 0 | |
| RT="$1" |