norman/ambry — pull request #12 by mauriciopasquier (2012-06-20 09:48:31+00:00)
Title: adapter name clash with default 'main' adapter

Just Installed Ambry (and generated its files)

$ rails c
.../ambry-0.3.0/lib/ambry.rb:35:in `register_adapter': Adapter :main already registered (Ambry::AmbryError)

Digging the code I notice you don't set the name for File and YAML adapters, so I tried the following
in adapters/yaml.rb:

def initialize(options)
options[:name] ||= :yaml
super
end

in adapters/file.rb:

def initialize(options)
@file_path = options[:file]
@read_only = !! options[:read_only]
@lock = Mutex.new
options[:name] ||= :file
super
end

But those changes caused a lot of errors to the specs that I couldn't trace, sorry for not providing more code.