Skip to content

Instantly share code, notes, and snippets.

View dtan4's full-sized avatar

Daisuke Fujita dtan4

View GitHub Profile
#!/usr/bin/env ruby
require "RMagick"
list = []
10.times do |i|
list << "lena_#{i}.png"
end
#!/bin/bash
base_dir=`pwd`
wget https://mecab.googlecode.com/files/mecab-0.996.tar.gz
tar zxfv mecab-0.996.tar.gz
cd mecab-0.996
./configure --enable-utf8-only
make
make check
tell application "iTunes"
set trackLyrics to lyrics of current track
return trackLyrics
end tell
@dtan4
dtan4 / Dockerfile
Created January 21, 2015 06:51
Minimal Sinatra Application on Docker
FROM ruby:2.2.0
RUN bundle config --global frozen 1
RUN mkdir -p /usr/src/app
WORKDIR /usr/src/app
ADD Gemfile /usr/src/app/
ADD Gemfile.lock /usr/src/app/
RUN bundle install --without test development --system
@dtan4
dtan4 / changed-specs
Last active August 29, 2015 14:16
Extract spec files which were changed from specified branch/commit
#!/usr/bin/env ruby
#
# Example usage
# - Test only changed model files & specs from master
# $ bundle exec rspec $(script/changed-specs model master)
#
require "open3"
require "shellwords"

実践 GitHub Flow

  • @cobyism
  • GitHub
    • 9.7M devs
    • 23.3M projects
    • 293 employees
    • 65% remote
    • 北米と西欧がメイン、アジアも日本中国台湾フィリピンあたり

GitHub Flow

開発戦略性を上げるためのデプロイ戦略

  • 吉羽さん

deploy

  • あらゆる環境へのコードやバイナリ、アセットなどの配布
  • インフラの構築はプロビジョニング

amazon

  • amazon.com
  • 平日のデプロイ感覚 11.6s

クックパッドはなぜ開発しやすいのか

  • @mirakui

cookpad

  • 2M recipes
  • 52M UB
  • 1.6M Premium Service Users
  • 1000 EC2
  • 15,000 req/s
  • 7 ops

サーバにログインしない・させないサービス運用

  • @koid
    • 後方支援系エンジニア

Gunosy

  • 26 devs
    • 5 analysis + contents
    • 1 infra
  • API
  • golang
#!/usr/bin/env ruby
require "fileutils"
require "open3"
def ghq_name_of(repository_url)
case repository_url
when %r(\Agit@)
repository_url.gsub(%r(\Agit@), "").sub(":", "/").gsub(%r(\.git\z), "")
when %r(\Agit://)