Posted by masuidrive Sat, 06 May 2006 08:54:00 GMT Railsでアプリを作るときの始めの作業をまとめて、自分メモがてから書いておきます。 まずは、いまさらsubversion解ってきた で紹介した、自作のrails.create コマンドでプロジェクトのディレクトリを作り、自動でsvnにまで入れます。 このコマンドでは、railsコマンドでプロジェクトのディレクトリを作り、database.ymlを自動設定して、logなど必要のない部分を除いてsvnのimportしてくれるコマンドです。 もしsvn使わないなら、railsコマンドとdatabase.ymlを手動でやってもOK。 続いてsessionをDBに保存するために、config/envitoment.rbに下記の1行のコメントを削除して、イキにします。
今回はRoRでアジャイルプロトタイピングの実践編として、筆者が特に気に入っているデータベースのマイグレーション機能を紹介したいと思います。データベースのマイグレーションはプロトタイピングのみならず、それ以降のフェーズでも活用できる非常に有用な機能であると考えています。 マイグレーションとは何か? そもそもマイグレーションとは何でしょうか? マイグレーション、特にデータベースにおけるマイグレーションとは、新しい環境に移行する際、整合性を保持したまま移行を行うためのツールであるといえるかと思います。 RoRにおけるマイグレーション RoRにおけるマイグレーション機能はActiveRecord::Migrationとそれを利用するフロントエンドに当たるRakeによって実現されています。 RakeはRuby Make、つまり、Ruby版makeとでもいえるビルドツールですが、記述言語としてRuby
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く