Sha256: 835c7b0155f86aae1705576972fb24e91d4b7ffdd4c4137b11cfd42f94ebea55

Contents?: true

Size: 953 Bytes

Versions: 7

Compression:

Stored size: 953 Bytes

Contents

This is a Rails plugin that provides datamapper as an orm

== Setup

add the following line to your projects environment.rb

config.gem "rails_datamapper"

== Generators

This will install the datamapper rake tasks:

script/generate dm_install

Three generators are added by default

script/generate dm_model
script/generate rspec_dm_model
script/generate dm_migration

The first two add a migration but you can call

script/generate dm_model --skip-migration
script/generate rspec_dm_model --skip-migration

To avoid any dependency on active record add this to your projects environment.rb

config.frameworks -= [ :active_record ]

== Session Store

Change config/initializers/session_store.rb to something like the following:

ActionController::Base.session_store = :data_mapper_store
ActionController::Base.session = {
    :expires_after => 7.days,
    :key           => '_session_id',
}

Then create the sessions table with: rake db:sessions:create

Version data entries

7 entries across 7 versions & 2 rubygems

Version Path
rails_datamapper-1.0.2 README.rdoc
rails_datamapper-1.0.1 README.rdoc
tpitale-rails_datamapper-0.10.3.1 README.rdoc
tpitale-rails_datamapper-0.10.3 README.rdoc
rails_datamapper-0.10.2 README.rdoc
rails_datamapper-0.10.1 README.rdoc
rails_datamapper-0.10.0 README.rdoc