Skip to content

Latest commit

 

History

History

props-activerecord

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 

props-activerecord

Manage Setting Hierarchies Addon for Database Support (ConfDb, Props Model, etc.)

Usage

DB - Config Database / Schema / Model

Example:

require 'props/activerecord'       # include database support

ConfDb.create    # build schema / tables (props)

Prop.create!( key: 'db.schema.version', '1.0.0' )

puts "Props:"
Prop.order( 'created_at asc' ).all.each do |prop|
  puts "  #{prop.key} / #{prop.value} | #{prop.created_at}"
end

More examples:

ConfDb.tables     # dump stats to console
ConfDb.delete!    # delete all records

License

The props-activerecord scripts are dedicated to the public domain. Use it as you please with no restrictions whatsoever.