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
*DateTime> show (MkLocalDateTime (MkTimeZone "GMT" (MkOffset (+) (MkInstant (MkHour 1) (MkMin 30) (MkSec 0)))) (MkDateTime (MkDate (MkYear 1991) September (MkDay 28)) (MkInstant (MkHour 21) (MkMin 12) (MkSec 0)))) | |
"1991-09-28T21:12:00+01:30" : String | |
*DateTime> MkLocalDateTime (MkTimeZone "GMT" (MkOffset (+) (MkInstant (MkHour 1) (MkMin 30) (MkSec 0)))) (MkDateTime (MkDate (MkYear 1991) September (MkDay 28)) (MkInstant (MkHour 21) (MkMin 12) (MkSec 0))) | |
MkLocalDateTime (MkTimeZone "GMT" (MkOffset (+) (MkInstant (MkHour 1) (MkMin 30) (MkSec 0)))) | |
(MkDateTime (MkDate (MkYear 1991) September (MkDay 28)) (MkInstant (MkHour 21) (MkMin 12) (MkSec 0))) : LocalDateTime (MkTimeZone "GMT" | |
(MkOffset (+) | |
(MkI |
// @flow | |
/* | |
"Proof in functions" by @mbrandonw | |
implemented in JavaScript and using Flow as a static type checker | |
Original post: | |
http://www.fewbutripe.com/swift/math/2015/01/06/proof-in-functions.html |
alias accio=wget | |
alias avadaKedavra='rm -f' | |
alias imperio=sudo | |
alias priorIncantato='echo `history |tail -n2 |head -n1` | sed "s/[0-9]* //"' | |
alias stupefy='sleep 5' | |
alias wingardiumLeviosa=mv | |
alias sonorus='set -v' | |
alias quietus='set +v' |
#!/usr/bin/env node | |
//please requist your app token from | |
//https://trello.com/1/connect?key=yourkey&name=git-hook&expiration=never&response_type=token&scope=read,write | |
var key = "your key"; | |
var token = "your token"; | |
//https://trello.com/board/-/4e9003324a517dad44465056 | |
var board_id = "4e9003324a517dad44465056"; | |
var Trello = require("node-trello"); |
In case you want to use the PATCH verbin Rack::Test and you get errors when you try it with the current gem release you will have to use the git version in your Gemfile:
group :test do
gem 'rack-test', :git => "https://github.com/brynary/rack-test.git"
While the PATCH verb has been included in a recent patch it's not yet in the gem release. Using the :git repo lets you test also PATCH routes for your rack app.
#!/usr/bin/env ruby | |
# This pre-commit hook will prevent any commit to forbidden branches | |
# (by default, "staging" and "production"). | |
# Put this file in your local repo, in the .git/hooks folder | |
# and make sure it is executable. | |
# The name of the file *must* be "pre-commit" for Git to pick it up. | |
FORBIDDEN_BRANCHES = ["staging", "production"] |
require 'epitools' | |
require 'redcarpet' | |
require 'coderay' | |
def indented?(text) | |
indent_sizes = text.lines.map{ |line| if line =~ /^(\s+)/ then $1 else '' end }.map(&:size) | |
indent_sizes.all? {|dent| dent > 0 } | |
end | |
def unwrap(text) |
.foo { | |
color: #f00; | |
} | |
.foo__bar { | |
color: #00f; | |
} |
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=0, minimum-scale=1.0, maximum-scale=1.0"> | |
<meta name="apple-mobile-web-app-capable" content="yes"> | |
<meta name="apple-mobile-web-app-status-bar-style" content="black"> | |
<title>iScroll demo: simple</title> |