Sha256: a6ca285bc9999691026f0e3de39ef2f67f5f6c925153b196c8bdb83f1755f2dc

Contents?: true

Size: 1.15 KB

Versions: 6

Compression:

Stored size: 1.15 KB

Contents

# Require forgeries at the bottom of the file so Forgery works as a gem both
# within rails and outside of it.

current_path = File.expand_path(File.dirname(__FILE__)) + '/'

# Loading forgery helpers.
require 'forgery/file_reader'
require 'forgery/file_writer'
require 'forgery/dictionaries'
require 'forgery/formats'

# Loading class extensions
Dir[current_path + 'forgery/extensions/**/*.rb'].uniq.each do |file|
  require file
end

# Load the forgery base class
require 'forgery/forgery'

# Load the forgery version
require 'forgery/version'

# Load the forgery api method
require 'forgery/forgery_api'

# Loading the other forgeries AFTER the initial forgery class is defined.
Dir[current_path + 'forgery/forgery/**/*.rb'].uniq.each do |file|
  require file
end

# Loading rails forgeries to override current forgery methods and add new forgeries
# Only run this for Rails < 3.0 since we need to use a Railtie to initialize >= 3.0
Forgery.load_from! "#{Forgery.rails_root}/lib/forgery" if Forgery.rails? && Rails::VERSION::STRING < "3.0.0"
# Include our Railtie if Rails >= 3.0.0
require 'forgery/forgery_railtie' if Forgery.rails? && Rails::VERSION::STRING >= "3.0.0"

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
forgery-0.3.12 lib/forgery.rb
forgery-0.3.11 lib/forgery.rb
forgery-0.3.10 lib/forgery.rb
forgery-0.3.9 lib/forgery.rb
forgery-0.3.8 lib/forgery.rb
forgery-0.3.7 lib/forgery.rb