3
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

rails プロジェクト構築手順

Last updated at Posted at 2016-05-03

rails プロジェクト構築手順

はじめに

いつも調べなおして面倒なので、まとめる.

bundle install

bundle init
bundle install --path vendor/bundler
rails new

gem のインストール先を決めとく。

gem

#haml
gem 'haml-rails'
gem 'erb2haml'

# Bootstrap
gem 'bootstrap-sass'
gem 'less-rails'
gem 'twitter-bootstrap-rails', '~> 2.2.8'

erb→hamlに変換する

rake haml:replace_erbs

bootstrap

Bootstrap のページからファイルをダウンロードし、vendor/assets に追加する.

インストールする

bundle exec rails g bootstrap:install
bundle exec rails g bootstrap:layout application fluid

git

git init

そのあと、ignoreファイルで vendor/bundler を指定しとく.

viewに適用

rails g bootstrap:themed Class名

参考ページ

3
2
1

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
3
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?