I hereby claim:
- I am morimori on github.
- I am morimori (https://keybase.io/morimori) on keybase.
- I have a public key ASAYIj_UuyAOKC9lqp7HpTanc3pGS_Oy1SwQBE54QRPyOAo
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
#! /bin/sh | |
echo "curl exit code\thttp status code\turl" | |
while read url ; do | |
http_status=$(curl -L -f -s -A 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10.9; rv:29.0) Gecko/20100101 Firefox/29.0' "${url}" -o /dev/null -w '%{http_code}\n') | |
echo "${?}\t${http_status}\t${url}" | |
sleep 1 | |
done < $1 |
ACCESS_KEY = 'YOUR ACCESS KEY' | |
SECRET_KEY = 'YOUR SECRET KEY' | |
MAX_SNAPSHOTS = 5 | |
require 'rubygems' | |
require 'aws-sdk' | |
require 'json' | |
require 'open-uri' | |
config = JSON.parse open('http://169.254.169.254/latest/dynamic/instance-identity/document').read |
def a(i = 0) | |
print 0x08.chr * i.to_s.size; print i | |
raise if i < 100000 | |
rescue | |
i += 1 | |
retry | |
end | |
def b(i = 0) | |
print 0x08.chr * i.to_s.size; print i |
require 'benchmark' | |
c = 100000 | |
sa = 'abc' | |
sb = 'def' | |
sc = 'ghi' | |
Benchmark.bmbm do |x| | |
x.report('<<') do | |
c.times{ s = ''; s << sa << sb << sc } | |
end |
# Block commit include focus tag for test | |
git stash --keep-index -q | |
FOCUS_TAGS=$(grep -rn ':focus => true' spec/*/**) | |
result=$? | |
git stash pop -q | |
if [ $result -eq 0 ]; then | |
echo "### PLEASE REMOVE FOCUS TAGS ###" | |
echo "$FOCUS_TAGS" | |
exit 1 | |
fi |
class A | |
@@a = 1 | |
end |
find -type f -print0 | xargs -0 file | grep SQLite | awk -F : '{print $1}' | xargs -n1 -d "\n" sqlite_optimizer.sh |
#! /bin/sh | |
# 0. 設定 | |
RELEASE=1.kray | |
ARCH=i386 | |
EC2_PRIVATE_KEY=/path/to/private_key.pem | |
EC2_CERT=/path/to/certificate.pem | |
S3_BUCKET=bucket-name | |
AWS_ACCOUNT_NUMBER=012345678910 | |
AWS_ACCESS_KEY=youraccesskey |
#! /bin/sh | |
# Run all specs | |
git stash --keep-index | |
RAILS_ENV=test bundle exec rake assets:precompile jasmine:headless assets:clean spec | |
result=$? | |
git stash pop | |
[ $result -ne 0 ] && exit $result |