http://github.com/camping/camping/compare/4539baf...6347baf

Latest changes in Camping:
1. There is now a Camping.options
2. Session now uses the Camping.options above
3. Fast Tilt integration (ERB/Haml support!)
4. Various changes

gem install camping --source http://gems.judofyr.net/

Any comments or improvements? Have I done anything stupid?

I think I'll rather go for the
commit-to-master-and-revert-if-theres-something-wrong, than the
commit-to-branch-or-fork-and-merge-when-ready.

--

1. There is now a Camping.options

Useful (mostly for plugins) when you need to set different options:

  module App
    set :hello, "foo"
  end

  App.options[:hello] == "foo"

--

2. Session now uses the Camping.options above

I want every setting to use Camping.options, so here's the new way:

  module App
    set :secret, "KEEP IT SECRET"
    include Camping::Session
  end

--

3. Fast Tilt integration

  module App
    set :views, File.dirname(__FILE__) + '/views'

    module Controllers
      class Index
        def get
          render :index
        end
      end
    end
  end

If you now create a file called views/index.haml, `render` will now
render that file (instead of looking for a Markaby method). You can
also create views/layout.haml and it will wrap it (`yield` will return
the inner template). You can of course also use views/index.erb or any
other template engine which Tilt supports (see
http://github.com/rtomayko/tilt)

--

4. Various changes

* require 'camping-unabridged' now marks itself as 'camping' was
required, and nothing happesn if you do require 'camping' later (great
for development!)

* Camping::Server now uses Rack::Server is a lot more cleaner.

* The session is now stored as a Hash, and not a App::H. This caused
me some weird bugs.

* Use Class#method_defined? instead of Class#instance_method rescue nil

* Fix bug in rake diff



// Magnus Holm
_______________________________________________
Camping-list mailing list
Camping-list@rubyforge.org
http://rubyforge.org/mailman/listinfo/camping-list

Reply via email to