active_lucene 0.5.0 → 0.5.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/Rakefile CHANGED
@@ -3,23 +3,23 @@ require 'rubygems/specification'
3
3
  require 'rake'
4
4
  require 'rake/gempackagetask'
5
5
  require 'spec/rake/spectask'
6
-
6
+
7
7
  GEM = "active_lucene"
8
- GEM_VERSION = "0.5.0"
8
+ GEM_VERSION = "0.5.1"
9
9
  SUMMARY = "ActiveRecord/ActiveModel's like interface for Lucene"
10
10
  AUTHOR = "Diego Carrion"
11
11
  EMAIL = "dc.rec1@gmail.com"
12
12
  HOMEPAGE = "http://www.diegocarrion.com"
13
13
 
14
-
14
+
15
15
  spec = Gem::Specification.new do |s|
16
16
  s.name = GEM
17
17
  s.version = GEM_VERSION
18
18
  s.platform = Gem::Platform::RUBY
19
19
  s.summary = SUMMARY
20
20
  s.require_paths = ['lib']
21
- s.files = FileList['lib/**/*.rb', '[A-Z]*'].to_a
22
-
21
+ s.files = FileList['lib/**/*', '[A-Z]*'].to_a
22
+
23
23
  s.author = AUTHOR
24
24
  s.email = EMAIL
25
25
  s.homepage = HOMEPAGE
@@ -29,19 +29,19 @@ Spec::Rake::SpecTask.new do |t|
29
29
  t.spec_files = FileList['spec/**/*_spec.rb']
30
30
  t.spec_opts = %w(-fs --color)
31
31
  end
32
-
32
+
33
33
  Rake::GemPackageTask.new(spec) do |pkg|
34
34
  pkg.gem_spec = spec
35
35
  end
36
-
36
+
37
37
  desc "Install the gem locally"
38
38
  task :install => [:package] do
39
39
  sh %{sudo gem install pkg/#{GEM}-#{GEM_VERSION}}
40
40
  end
41
-
41
+
42
42
  desc "Create a gemspec file"
43
43
  task :make_spec do
44
44
  File.open("#{GEM}.gemspec", "w") do |file|
45
45
  file.puts spec.to_ruby
46
46
  end
47
- end
47
+ end
data/lib/active_lucene.rb CHANGED
@@ -20,8 +20,13 @@ import org.apache.lucene.search.highlight.Highlighter
20
20
 
21
21
  import org.apache.lucene.util.Version
22
22
 
23
- APP_ROOT ||= RAILS_ROOT if defined?(RAILS_ROOT)
24
- APP_ENV ||= RAILS_ENV if defined?(RAILS_ENV)
23
+ if defined? RAILS_ROOT
24
+ APP_ROOT = RAILS_ROOT
25
+ APP_ENV = RAILS_ENV
26
+ else
27
+ APP_ROOT ||= '.'
28
+ APP_ENV ||= 'default'
29
+ end
25
30
 
26
31
  %w(analyzer document index query searcher term writer).each { |name| require "active_lucene/#{name}" }
27
32
 
Binary file
Binary file
Binary file
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: active_lucene
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.0
4
+ version: 0.5.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Diego Carrion
@@ -9,7 +9,7 @@ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
 
12
- date: 2010-01-23 00:00:00 -02:00
12
+ date: 2010-01-26 00:00:00 -02:00
13
13
  default_executable:
14
14
  dependencies: []
15
15
 
@@ -22,16 +22,20 @@ extensions: []
22
22
  extra_rdoc_files: []
23
23
 
24
24
  files:
25
+ - lib/active_lucene.rb
26
+ - lib/lucene-highlighter-3.0.0.jar
27
+ - lib/lucene-queryparser-3.0.0.jar
28
+ - lib/lucene-core-3.0.0.jar
29
+ - lib/lucene-memory-3.0.0.jar
25
30
  - lib/active_lucene/analyzer.rb
31
+ - lib/active_lucene/writer.rb
26
32
  - lib/active_lucene/document.rb
27
33
  - lib/active_lucene/index.rb
28
- - lib/active_lucene/query.rb
29
34
  - lib/active_lucene/searcher.rb
35
+ - lib/active_lucene/query.rb
30
36
  - lib/active_lucene/term.rb
31
- - lib/active_lucene/writer.rb
32
- - lib/active_lucene.rb
33
- - Rakefile
34
37
  - README.textile
38
+ - Rakefile
35
39
  has_rdoc: true
36
40
  homepage: http://www.diegocarrion.com
37
41
  licenses: []