1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

Move railties/builtin into lib

This commit is contained in:
Joshua Peek 2010-03-20 12:34:21 -05:00
parent f868c2afa9
commit f38e89cfba
12 changed files with 12 additions and 17 deletions

View file

@ -1,2 +0,0 @@
module Rails::InfoHelper
end

View file

@ -1,5 +1,4 @@
require 'fileutils'
require 'rails/railties_path'
require 'rails/plugin'
require 'rails/engine'

View file

@ -78,7 +78,7 @@ module Rails
end
def builtin_controller
File.join(RAILTIES_PATH, "builtin", "rails_info") if Rails.env.development?
File.expand_path('../info_routes', __FILE__) if Rails.env.development?
end
def log_level

View file

@ -23,7 +23,7 @@ module Rails
initializer :add_builtin_route do |app|
if Rails.env.development?
app.routes_reloader.paths << File.join(RAILTIES_PATH, 'builtin', 'routes.rb')
app.routes_reloader.paths << File.expand_path('../../info_routes.rb', __FILE__)
end
end

View file

@ -1 +0,0 @@
RAILTIES_PATH = File.expand_path(File.join(File.dirname(__FILE__), '..', '..'))

View file

@ -72,7 +72,8 @@ namespace :doc do
desc "Generate Rails guides"
task :guides do
require File.join(RAILTIES_PATH, "guides/rails_guides")
# FIXME: Reaching outside lib directory is a bad idea
require File.expand_path('../../../../guides/rails_guides', __FILE__)
RailsGuides::Generator.new(Rails.root.join("doc/guides")).generate
end

View file

@ -15,7 +15,6 @@ end
desc 'Explain the current environment'
task :about do
$LOAD_PATH.unshift "#{RAILTIES_PATH}/builtin/rails_info"
require 'rails/info'
puts Rails::Info
end

View file

@ -13,7 +13,7 @@ Gem::Specification.new do |s|
s.homepage = 'http://www.rubyonrails.org'
s.rubyforge_project = 'rails'
s.files = Dir['CHANGELOG', 'README', 'bin/**/*', 'builtin/**/*', 'guides/**/*', 'lib/**/{*,.[a-z]*}']
s.files = Dir['CHANGELOG', 'README', 'bin/**/*', 'guides/**/*', 'lib/**/{*,.[a-z]*}']
s.require_path = 'lib'
s.bindir = 'bin'
s.executables = ['rails']

View file

@ -1,7 +1,6 @@
ORIG_ARGV = ARGV.dup
require File.expand_path("../../../load_paths", __FILE__)
$:.unshift File.expand_path("../../builtin/rails_info", __FILE__)
require 'stringio'
require 'test/unit'