mirror of https://github.com/apache/lucene.git
Update to require Rails 1.2.3
git-svn-id: https://svn.apache.org/repos/asf/lucene/solr/trunk@528296 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
021f4eef00
commit
46873c3ccc
|
@ -9,4 +9,4 @@ require 'rake/rdoctask'
|
||||||
|
|
||||||
require 'tasks/rails'
|
require 'tasks/rails'
|
||||||
|
|
||||||
require 'solr/solrtasks'
|
#require 'solr/solrtasks'
|
|
@ -3,7 +3,7 @@
|
||||||
unless defined?(RAILS_ROOT)
|
unless defined?(RAILS_ROOT)
|
||||||
root_path = File.join(File.dirname(__FILE__), '..')
|
root_path = File.join(File.dirname(__FILE__), '..')
|
||||||
|
|
||||||
unless RUBY_PLATFORM =~ /mswin32/
|
unless RUBY_PLATFORM =~ /(:?mswin|mingw)/
|
||||||
require 'pathname'
|
require 'pathname'
|
||||||
root_path = Pathname.new(root_path).cleanpath(true).to_s
|
root_path = Pathname.new(root_path).cleanpath(true).to_s
|
||||||
end
|
end
|
||||||
|
@ -26,7 +26,7 @@ unless defined?(Rails::Initializer)
|
||||||
rails_gem = Gem.cache.search('rails', "~>#{version}.0").sort_by { |g| g.version.version }.last
|
rails_gem = Gem.cache.search('rails', "~>#{version}.0").sort_by { |g| g.version.version }.last
|
||||||
|
|
||||||
if rails_gem
|
if rails_gem
|
||||||
require_gem "rails", "=#{rails_gem.version.version}"
|
gem "rails", "=#{rails_gem.version.version}"
|
||||||
require rails_gem.full_gem_path + '/lib/initializer'
|
require rails_gem.full_gem_path + '/lib/initializer'
|
||||||
else
|
else
|
||||||
STDERR.puts %(Cannot find gem for Rails ~>#{version}.0:
|
STDERR.puts %(Cannot find gem for Rails ~>#{version}.0:
|
||||||
|
@ -36,10 +36,10 @@ unless defined?(Rails::Initializer)
|
||||||
exit 1
|
exit 1
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
require_gem "rails"
|
gem "rails"
|
||||||
require 'initializer'
|
require 'initializer'
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
Rails::Initializer.run(:set_load_path)
|
Rails::Initializer.run(:set_load_path)
|
||||||
end
|
end
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
# ENV['RAILS_ENV'] ||= 'production'
|
# ENV['RAILS_ENV'] ||= 'production'
|
||||||
|
|
||||||
# Specifies gem version of Rails to use when vendor/rails is not present
|
# Specifies gem version of Rails to use when vendor/rails is not present
|
||||||
RAILS_GEM_VERSION = '1.2.2' unless defined? RAILS_GEM_VERSION
|
RAILS_GEM_VERSION = '1.2.3' unless defined? RAILS_GEM_VERSION
|
||||||
|
|
||||||
# Bootstrap the Rails environment, frameworks, and default configuration
|
# Bootstrap the Rails environment, frameworks, and default configuration
|
||||||
require File.join(File.dirname(__FILE__), 'boot')
|
require File.join(File.dirname(__FILE__), 'boot')
|
||||||
|
@ -64,14 +64,16 @@ solr_environments = {
|
||||||
# timeline: default, no timeline support without knowing the field(s) to use
|
# timeline: default, no timeline support without knowing the field(s) to use
|
||||||
|
|
||||||
:development => {
|
:development => {
|
||||||
|
:solr_query_type => :standard,
|
||||||
},
|
},
|
||||||
|
|
||||||
:delicious => {
|
:delicious => {
|
||||||
:timeline_dates => :published_year_facet,
|
:timeline_dates => :published_year_facet,
|
||||||
:image_proc => Proc.new {|doc| "http://images.amazon.com/images/P/#{doc['asin_text']}.01.MZZZZZZZ"}
|
:image_proc => Proc.new {|doc| "http://images.amazon.com/images/P/#{doc['asin_text']}.01.MZZZZZZZ"},
|
||||||
},
|
},
|
||||||
|
|
||||||
:tang => {
|
:tang => {
|
||||||
|
:solr_query_type => :standard,
|
||||||
},
|
},
|
||||||
|
|
||||||
:marc => {
|
:marc => {
|
||||||
|
|
Loading…
Reference in New Issue