New versions of Nitro and Og were just released!
Another step closer to web programming nirvana. This release
features completely recoded scaffolding, an auto admin system,
a recoded template-morphing system, a new intelligent dispatcher
that handles both nice urls and general structure, and so much
more. Moreover, this is the release with the most community
contributions. Download now!
Most notable changes:
New, intelligent dispatcher handles nice urls automatically,
without explicit rewrite rules. At the same time, it handles
sub directories, so you are free to design your app’s
structure as you like.
New template morphing implementation. The morphing compileropt1
is fully customizable. You can implement your own morphers and
add them to the morphing system, here for example is the
new selected_if morpher:
becomes<?r if @cond ?> opt1 <?r else ?> opt1 <?r end ?>
New Sweeper mixin. Using this mixin allows you to keep
the cleanup logic in one place. This logic is called
automagically by many default Nitro/Og methods (for example
Og insert/update, scaffolding, etc). You can fully customize
def sweep_affected(action = :all)
a = Article
a.title = ‘New’
a.save # => calls expire_affected.
This mixin is typically used to automatically clean up output
caching files from the filesystem, but you can use it to remove
temp rows from the database, or temp objects from a drb server
or anything you like.
Searchable mixin. Include this mixin to your classes to make
them searchable by the auto administration system.
Added two new session managers (OgSession, FileSession),
cleaned up the session code.
Better validations implementation. Cleaner code, less evals,
more flexible and easier to extend.
New scaffolding / auto administration system. The implementation
is much cleaner and easier to customize. It leverages the latest
advancements (dispatcher, sweeper, etc) and adds search support,
pager, breadcrumps and more. You can define your own controls
to handle properties and relations. Stay tuned for more stuff
in the near future.
New Og revisable mixin. Just include this mixin in your classes
and get db backed revision support for free. Here comes an
property :body, String, :revisable => true
property :title, String
Automatically generates the Revision class (and the
article.revise do |a|
a.title = ‘hello’
a.body = ‘world’
Bug fixed KirbyBase Og adapter. This works great with the
new 2.5 gem.
Added more rational defaults, and many predefined options to
minimize the amount of setup needed to get your app running. Of
course you can still customize just about everything in Nitro.
Improvements to PostgreSQL automatic generation of foreign key
Added evolution support to the MySql store.
Upgrated to Prototype 1.4 and Scriptaculous 1.5
Updated the examples, check out the improved blog and why_wiki
Many, many, many bug fixes and smaller improvements.
Nitro provides everything you need to develop professional Web
Nitro redefines Rapid Application Development by providing a
clean, yet efficient API, a layer of domain specific languages
implemented on top of Ruby and the most powerful and elegant
object relational mapping solution available everywhere.