Project

stirling

0.01
No commit activity in last 3 years
No release in over 3 years
Rails extension tool
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
 Dependencies

Runtime

 Project Readme

Stirling Build Status Gem Version

Stirling provides some architectures for Rails to develop quickly.

Usage

Add to your Gemfile.

gem "stirling"

Functions

BaseController

BaseController automatically creates instance variable corresponding to controller name. For example:

UserController -> @user

and assigns parameter to instance variable.

Re-create db task

Stirling provides command to re-create db like following.

$ rake db:recreate

Strong Parameters

In Stirling, accepting attributes is handeled to use acceptable_attributes, class method in model. You have to do like following.

class User < ActiveRecord::Base
  class << self
    def acceptable_attributes
      [:name, :age, :email]
    end
  end
end

acceptable_attributes is inserted automatically in model if you generate to use rails g model MODEL_NAME.

Copyright

This project rocks and uses MIT-LICENSE.