2015-01-01から1ヶ月間の記事一覧

Vagrant&VirtualBoxをインストール

VirtualBoxをインストール https://www.virtualbox.org/wiki/Downloads Vagrantをインストール https://www.vagrantup.com/downloads.html vagrantに仮装環境を追加 vagrant box add centos64 http://developer.nrel.gov/downloads/vagrant-boxes/CentOS-6.4…

Rails + Paperclipを試す

プロジェクトを新規作成 $rails new paperclipdemo -d mysql $cd paperclipdemo $bundle install --path vendor/bundler $rails s -p80 scaffoldを作成 $rails g scaffold events name:string $rake db:create $rake db:migrate Gemをupdate(PaperclipとAWS-…

resourcesメソッドを指定してRESTfulなルーティングを作る

1.Controllerの作成 $rails g controller books index show new crete edit destroy update 2.ルーティングを作成 vim config/routes.rb========================================= #既に作られているルーティングをコメントアウト(削除) #get 'books/index'…