FridayHug.com http://fridayhug.com
The Smallest Rails App http://thesmallestrailsapp.com
%w(action_controller/railtie coderay).each &method(:require)| <body> | |
| <div class="container"> | |
| <%= render "layouts/header" %> | |
| <%= flash_messages %> | |
| <%= yield %> | |
| <%= render "layouts/footer" %> | |
| </div | |
| </body> |
FridayHug.com http://fridayhug.com
The Smallest Rails App http://thesmallestrailsapp.com
%w(action_controller/railtie coderay).each &method(:require)| git :init | |
| git add: "." | |
| git commit: %Q{ -m 'Initial commit' } | |
| # Twitter bootstrap baby | |
| gem 'twitter-bootstrap-rails', :git => 'git://github.com/seyhunak/twitter-bootstrap-rails.git' | |
| # Incase you want less | |
| gem 'less-rails' | |
| # jQuery is the win | |
| gem 'jquery-rails' |
| # coding: utf-8 | |
| # This is a Rails init template | |
| # Usage | |
| # | |
| # $ rails new app_name -d postgresql -m https://raw.github.com/gist/3303948 --skip-bundle | |
| # | |
| # remove files | |
| run "rm README.rdoc" | |
| run "touch README.md" |
| ## Rails App Template | |
| ## Updated for Rails 3.2.8 | |
| ## Updated on 9/24/12 | |
| ## Run using $ rails new [appname] -JT -m https://raw.github.com/gist/960988/template.rb | |
| ## Gems | |
| # General | |
| gem 'rake', '0.9.2.2' | |
| # Warden and Devise for security |
| # add gems | |
| gem 'whenever' | |
| gem 'kaminari' | |
| gem 'hpricot' | |
| gem 'ruby_parser' | |
| gem 'jquery-rails' | |
| gem "jquery-ui-rails" | |
| gem 'bcrypt-ruby', '~> 3.0.0' | |
| gem "rspec-rails", :group => [ :development, :test ] | |
| gem "ffaker", :group => :test |
| # Helpers | |
| def git_update(message) | |
| git :add => ".", :commit => "-m '#{message}'" | |
| end | |
| def git_remove(file) | |
| git :rm => file | |
| end |
| { | |
| "after_callback": "", | |
| "auto_complete_commit_on_tab": true, | |
| "before_callback": "", | |
| "bold_folder_labels": true, | |
| "check_for_bundler": true, | |
| "check_for_rbenv": true, | |
| "check_for_rvm": true, | |
| "check_for_spring": true, | |
| "color_scheme": "Packages/User/Flatland Monokai (SL).tmTheme", |
| # Update, upgrade and install development tools: | |
| sudo apt-get update | |
| sudo apt-get -y upgrade | |
| sudo apt-get -y install build-essential git-core libssl-dev libsqlite3-dev curl nodejs nginx | |
| # Install rbenv | |
| git clone git://github.com/sstephenson/rbenv.git ~/.rbenv | |
| # Add rbenv to the path: | |
| echo 'export RBENV_ROOT=~/.rbenv' >> ~/.bash_profile |
This guide enables you to install (ruby-build) and use (rbenv) multiple versions of ruby, isolate project gems (gemsets and/or bundler), and automatically use appropriate combinations of rubies and gems.
# Ensure system is in ship-shape.
aptitude install git zsh libssl-dev zlib1g-dev libreadline-dev libyaml-dev