俺のrails開発環境
DESCRIPTION
自分のRails開発環境とちょっとした小技について書いてみた。TRANSCRIPT
俺のRails開発環境
@joker1007Tomohiro Hashidate
ジョジョエヴァンジェリスト
2012年5月16日水曜日
人の開発環境って結構気になりません?
2012年5月16日水曜日
自分から晒してみる
2012年5月16日水曜日
概要使ってるもの
rvmvimzsh
screengit
jenkins
無いと始まらないGemrspecpry
guardtapp
開発に使ってるOSMac
Linux (Ubuntu, Gentoo)2012年5月16日水曜日
テスト•ユニットテスト•RSpec•インテグレーションテスト•cucumber
•javascriptユニットテスト•jasmine-headless-webkit
2012年5月16日水曜日
Railsへの入口
• rvmで適当にgemsetを作り、railsをインストール
• rails new appname -T -m <template gist> --skip-bundle
• bundle install --path vendor/bundle
2012年5月16日水曜日
テストの準備• bundle exec rails g rspec:install• bundle exec guard init rspec (guard-rspec)
• bundle exec guard init spork (guard-spork)
• guard 'rspec', :version => 2, :cli => "--format d --color --drb", :all_on_start => false, :all_after_pass => false
2012年5月16日水曜日
テストの準備(大規模の時)• database: appname_test<%= ENV['TEST_ENV_NUMBER'] %>
• bundle exec rake parallel:create• .rspec_parallel• --format progress
• --format ParallelTests::RSpec::RuntimeLogger --out tmp/parallel_runtime_rspec.log
2012年5月16日水曜日
書き方
•bundle exec guard start•sporkが立ち上がって監視状態•specファイルを書いて、動作確認。•後はせっせとTDD
2012年5月16日水曜日
便利な小技シリーズ
•zsh編•alias g=‘git’•aias be=‘bundle exec’•vcs_info
2012年5月16日水曜日
2012年5月16日水曜日
便利な小技シリーズ•git編•alias•lgraph = log --oneline --graph --decorate --all -n 20
•color•ui = auto
2012年5月16日水曜日
2012年5月16日水曜日
便利な小技シリーズ•vim編
•vim-altr
•fugitive•quickrun•erromarker
•unite-grep + qfreplace2012年5月16日水曜日
F2, F3でspecと実装コードを切り替え
2012年5月16日水曜日
• statuslineに%{fugitive#statusline()}を追記
2012年5月16日水曜日
DEMO
2012年5月16日水曜日
質問・突っ込みなど
2012年5月16日水曜日