Agile Software Development with Edge Ruby
Ruby / Rails をもちいたソフトウェア開発の中で、Ruby の開発バージョン (発表時 2.3.0-dev) を取り入れているお話をします。本番環境は本番環境、開発環境は開発環境ということで、明日から個人ではじめられる話です。 プログラミングを楽しくする言語 Ruby のことをもっと知りたいという気持ちを持ち帰って頂ければ幸いです。
$ ruby -v ✖ ✹ ✭ | |
ruby 2.2.0p0 (2014-12-25 revision 49005) [x86_64-darwin13] | |
$ PKG_CONFIG_PATH=/usr/local/opt/libffi/lib/pkgconfig gem install rabbit | |
Fetching: glib2-3.0.5.gem (100%) | |
Building native extensions. This could take a while... | |
Successfully installed glib2-3.0.5 | |
Fetching: gobject-introspection-3.0.5.gem (100%) | |
Building native extensions. This could take a while... | |
Successfully installed gobject-introspection-3.0.5 | |
Fetching: gio2-3.0.5.gem (100%) |
# Activate the gem you are reporting the issue against. | |
gem 'activerecord', '4.2.5' | |
gem 'activerecord-oracle_enhanced-adapter', '1.6.5' | |
require 'active_record' | |
require 'minitest/autorun' | |
require 'logger' | |
require 'active_record/connection_adapters/oracle_enhanced_adapter' | |
# Ensure backward compatibility with Minitest 4 | |
Minitest::Test = MiniTest::Unit::TestCase unless defined?(Minitest::Test) |
mkdir foo | |
cp migration_archive.tar.gz foo/ | |
cd foo | |
git init | |
tar zxvf migration_archive.tar.gz | |
rm migration_archive.tar.gz | |
git add * | |
git commit -m * 'Initial commit' | |
rm users_*.json teams_*.json organizations_*.json | |
git commit . -m 'Remove org info' |
何かの拍子で 2.3.0 に旧バージョンの did_you_mean を入れていたらしい。。。
$ ruby -v -e 'def hi; hi; end; hi'
ruby 2.3.0p0 (2015-12-25 revision 53290) [x86_64-darwin13]
/Users/koic/.rbenv/versions/2.3.0/lib/ruby/gems/2.3.0/gems/interception-0.5/lib/cross_platform.rb:66:
warning: method redefined; discarding old start
/Users/koic/.rbenv/versions/2.3.0/lib/ruby/gems/2.3.0/gems/interception-0.5/lib/interception.rb:113: w
bundle exec rake db:migrate:status | sed 's/\s\{1,\}/ /g' | cut -f3 -d ' ' > tmp/schema.txt | |
# Remove the header of above file | |
ls db/migrate | sed 's/db\/migrate//g' | cut -f1 -d '_' > tmp/file.txt | |
diff tmp/schema.txt tmp/file.txt |
require 'yaml' | |
puts YAML.load(DATA.read) # => {"name"=>"Bob"} | |
__END__ | |
--- | |
name: Alice | |
name: Bob |