-
Vagrantfile
- Utilizes Vagrant and Parallels Desktop
- See: https://github.com/Parallels/boot2docker-vagrant-box
-
boot2docker.fish
- Fish-shell script
$__docker_vagrant_box_dir
: folder for vagrant box, defaults to~/opt/vagrant/docker
, created fromVagrantfile
if not exists. You might want to change it to a different location or use a different vagrant box.function docker
: bring up the vagrant box and run the originaldocker
commandfunction turn_off_docker_vagrant_box
: halt the vagrant box
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ISP Shanghai Telecom | |
bogus-nxdomain=180.168.41.175 | |
# OpenDNS | |
bogus-nxdomain=67.215.65.132 | |
bogus-nxdomain=67.215.77.132 | |
bogus-nxdomain=208.69.34.132 | |
bogus-nxdomain=208.69.32.132 | |
# DNSPai |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Foundation | |
let url = NSURL(string: "https://spdy.today/spdy.json") | |
let request = NSURLRequest(URL: url) | |
NSURLConnection.sendAsynchronousRequest(request, queue: NSOperationQueue.currentQueue()) { | |
_, data, _ in | |
if data { | |
let str = NSString(data: data, encoding: NSUTF8StringEncoding) | |
println(str) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# history, http://wiki.gentoo.org/wiki/Zsh/HOWTO#History | |
export HISTSIZE=2000 | |
export HISTFILE="$HOME/.history" | |
export SAVEHIST=$HISTSIZE | |
setopt hist_ignore_all_dups | |
setopt hist_ignore_space | |
# Banner | |
$HOME/bin/95-lolcat | |
/usr/local/bin/archey -c |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby | |
require 'rb-inotify' | |
if ARGV.count < 3 | |
puts "Usage: #{File.basename $0} <path> <signal> <cmd>" | |
exit 1 | |
end | |
path = ARGV[0] | |
signal = ARGV[1].to_sym |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
└───🌐 dig t0.example.rubyist.today +dnssec +trace | |
; <<>> DiG 9.9.5-4-Debian <<>> t0.example.rubyist.today +dnssec +trace | |
;; global options: +cmd | |
. 1037 IN NS e.root-servers.net. | |
. 1037 IN NS b.root-servers.net. | |
. 1037 IN NS c.root-servers.net. | |
. 1037 IN NS a.root-servers.net. | |
. 1037 IN NS g.root-servers.net. | |
. 1037 IN NS h.root-servers.net. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set shell=/bin/sh " fix for fish | |
set nocompatible " be iMproved | |
filetype on " see: http://unix.stackexchange.com/questions/14497/ | |
filetype off " required! | |
set rtp+=~/.vim/bundle/Vundle.vim | |
call vundle#begin() | |
Plugin 'gmarik/Vundle.vim' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import UIKit | |
import CoreLocation | |
@UIApplicationMain | |
class AppDelegate: UIResponder, UIApplicationDelegate, CLLocationManagerDelegate { | |
var window: UIWindow? | |
var locationManager: CLLocationManager! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby | |
begin | |
require 'unicorn' | |
rescue LoadError | |
abort "Required gem not found: unicorn" | |
end | |
if not File.exists? 'config.ru' | |
abort "Required file not found: ./config.ru" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
convert -crop 120x120+487+49 screenshot.png [email protected] |