Skip to content

Instantly share code, notes, and snippets.

iops_simple() {
local _dir="$1"
[[ -d "$_dir" ]] || return
local _output=$(mktemp fio_XXXX)
local _size="2G"
local -i _jobs=8
local _engine="vsync"
local -i _files=$((_jobs * 4))
local -i _depth=$((_jobs * 8))
iops_simple() {
local _dir="$1"
[[ -d "$_dir" ]] || return
local _output=$(mktemp fio_XXXX)
local _size="2G"
local -i _jobs=8
local _engine="vsync"
local -i _files=$((_jobs * 4))
local -i _depth=$((_jobs * 8))
#!/bin/bash
#------------------------------------------------------------------------------
# netfilter-pants
#
# The MIT License (MIT)
#
# Copyright (c) 1999 Chris Horn
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
#!/usr/bin/env bash
declare -i _COLUMNS=$(sh -O checkwinsize -i -c 'echo $COLUMNS')
((_COLUMNS > 80)) || _COLUMNS=80
declare -i _PIDW=7
declare -i _USERW=15
declare -i _PORTW=$(($_COLUMNS / 6))
declare -i _CMDW=_COLUMNS-_PIDW-_USERW-_PORTW-_PORTW-7
_truncate_cmd=3

Keybase proof

I hereby claim:

  • I am chorn on github.
  • I am chorn (https://keybase.io/chorn) on keybase.
  • I have a public key whose fingerprint is 5694 FB04 DD13 19D0 5C5D 8A10 65CB EA2B 9A68 DAB3

To claim this, I am signing this object:

unset __messy_path
unset __cleaned_path
unset __path_check
declare -A __path_check
__messy_path+=(/Applications/Sublime\ Text\ 2.app/Contents/SharedSupport/bin /Applications/VMware\ Fusion.app/Contents/Library /Applications/Postgres.app/Contents/Versions/{9.3,9.4}/bin /{usr,opt}/{local,X11}/{bin,sbin} $HOME/bin)
__messy_path+=($(IFS=:; echo $PATH))
__messy_path+=(/{usr,opt}/{bin,sbin} /{bin,sbin})
unset __messy_path
unset __cleaned_path
unset __path_check
declare -A __path_check
__messy_path+=(/Applications/Sublime\ Text\ 2.app/Contents/SharedSupport/bin /Applications/VMware\ Fusion.app/Contents/Library /Applications/Postgres.app/Contents/Versions/{9.3,9.4}/bin /{usr,opt}/{local,X11}/{bin,sbin} $HOME/bin)
__messy_path+=($(IFS=:; echo $PATH))
__messy_path+=(/{usr,opt}/{bin,sbin} /{bin,sbin})
@chorn
chorn / gcc49.rb
Created July 8, 2014 11:53
OS X Homebrew Formula compatible with Yosemite (10.10) and Xcode6 Beta as of 2014-07-08
require 'formula'
class Gcc49 < Formula
def arch
if Hardware::CPU.type == :intel
if MacOS.prefer_64_bit?
'x86_64'
else
'i686'
end
#!/usr/bin/env ruby_executable_hooks
#
# This file was generated by RubyGems.
#
# The application 'rails' is installed as part of a gem, and
# this file is here to facilitate running it.
#
require 'rubygems'
export LESS="irQ"
export HISTCONTROL=ignoreboth
export HISTFILESIZE=10000000
export HISTSIZE=1000
export INPUTRC="$HOME/.bash_inputrc"
export MAILCHECK=0
export PS1='\t \u@\h \w \$ '
umask 022
set -o emacs -o monitor -o notify