Skip to content

Instantly share code, notes, and snippets.

@croaky
Created January 17, 2010 18:26
Show Gist options
  • Save croaky/279487 to your computer and use it in GitHub Desktop.
Save croaky/279487 to your computer and use it in GitHub Desktop.
root = if defined?(Rails.root) && Rails.root
Rails.root
elsif defined?(RAILS_ROOT)
RAILS_ROOT
end
if root
# load in the 3rd party macros from vendorized plugins and gems
Shoulda.autoload_macros root, File.join("vendor", "{plugins,gems}", "*")
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment