1
0
Fork 0
mirror of https://github.com/awesome-print/awesome_print synced 2023-03-27 23:22:34 -04:00
awesome_print/lib/ap.rb

26 lines
1.2 KiB
Ruby
Raw Normal View History

2011-02-03 01:48:27 -05:00
# Copyright (c) 2010-2011 Michael Dvorkin
2010-04-03 00:43:46 -04:00
#
# Awesome Print is freely distributable under the terms of MIT license.
# See LICENSE file or http://www.opensource.org/licenses/mit-license.php
#------------------------------------------------------------------------------
#
# AwesomePrint might be loaded implicitly through ~/.irbrc so do nothing
# for subsequent requires.
#
unless defined?(AwesomePrint)
%w(array string method object class kernel).each do |file|
require File.dirname(__FILE__) + "/ap/core_ext/#{file}"
end
2010-04-22 00:57:21 -04:00
2011-05-13 19:24:01 -04:00
require File.dirname(__FILE__) + "/ap/inspector"
require File.dirname(__FILE__) + "/ap/formatter"
require File.dirname(__FILE__) + "/ap/core_ext/logger" if defined?(Logger)
require File.dirname(__FILE__) + "/ap/mixin/action_view" if defined?(ActionView)
# Load the following under normal circumstatnces as well as in Rails
# console when required from ~/.irbrc.
require File.dirname(__FILE__) + "/ap/mixin/active_record" if defined?(ActiveRecord) || (defined?(IRB) && ENV['RAILS_ENV'])
require File.dirname(__FILE__) + "/ap/mixin/active_support" if defined?(ActiveSupport) || (defined?(IRB) && ENV['RAILS_ENV'])
require File.dirname(__FILE__) + "/ap/mixin/mongo_mapper" if defined?(MongoMapper)
end