fizx-rwget 0.5.2 → 0.5.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (5) hide show
  1. data/Rakefile +1 -1
  2. data/VERSION +1 -1
  3. data/lib/rwget/dupes.rb +2 -3
  4. data/rwget.gemspec +4 -4
  5. metadata +2 -2
data/Rakefile CHANGED
@@ -12,7 +12,7 @@ begin
12
12
  gem.add_dependency("curb", ["> 0.0.0"])
13
13
  gem.add_dependency("hpricot", ["> 0.0.0"])
14
14
  gem.add_dependency("fizx-robots", [">= 0.3.1"])
15
- gem.add_dependency("bloomfilter", ["> 0.0.0"])
15
+ gem.add_dependency("igrigorik-bloomfilter", ["> 0.0.0"])
16
16
  gem.add_dependency("libxml-ruby", ["> 0.9"])
17
17
  end
18
18
  rescue LoadError
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.5.2
1
+ 0.5.3
@@ -6,14 +6,13 @@ class RWGet::Dupes
6
6
  SIZE = 1_000_000
7
7
 
8
8
  def initialize(options = {})
9
- @tmp = Tempfile.new("bloom")
10
- @bloom = ExternalBloomFilter.create(@tmp.path, SIZE)
9
+ @bloom = BloomFilter.new(SIZE, 4, 1)
11
10
  end
12
11
 
13
12
  def dupe?(uri)
14
13
  key = uri.to_s
15
14
  return true if @bloom.include?(key)
16
- @bloom.add(key)
15
+ @bloom.insert(key)
17
16
  return false
18
17
  end
19
18
  end
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{rwget}
8
- s.version = "0.5.2"
8
+ s.version = "0.5.3"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Kyle Maxwell"]
@@ -69,20 +69,20 @@ Gem::Specification.new do |s|
69
69
  s.add_runtime_dependency(%q<curb>, ["> 0.0.0"])
70
70
  s.add_runtime_dependency(%q<hpricot>, ["> 0.0.0"])
71
71
  s.add_runtime_dependency(%q<fizx-robots>, [">= 0.3.1"])
72
- s.add_runtime_dependency(%q<bloomfilter>, ["> 0.0.0"])
72
+ s.add_runtime_dependency(%q<igrigorik-bloomfilter>, ["> 0.0.0"])
73
73
  s.add_runtime_dependency(%q<libxml-ruby>, ["> 0.9"])
74
74
  else
75
75
  s.add_dependency(%q<curb>, ["> 0.0.0"])
76
76
  s.add_dependency(%q<hpricot>, ["> 0.0.0"])
77
77
  s.add_dependency(%q<fizx-robots>, [">= 0.3.1"])
78
- s.add_dependency(%q<bloomfilter>, ["> 0.0.0"])
78
+ s.add_dependency(%q<igrigorik-bloomfilter>, ["> 0.0.0"])
79
79
  s.add_dependency(%q<libxml-ruby>, ["> 0.9"])
80
80
  end
81
81
  else
82
82
  s.add_dependency(%q<curb>, ["> 0.0.0"])
83
83
  s.add_dependency(%q<hpricot>, ["> 0.0.0"])
84
84
  s.add_dependency(%q<fizx-robots>, [">= 0.3.1"])
85
- s.add_dependency(%q<bloomfilter>, ["> 0.0.0"])
85
+ s.add_dependency(%q<igrigorik-bloomfilter>, ["> 0.0.0"])
86
86
  s.add_dependency(%q<libxml-ruby>, ["> 0.9"])
87
87
  end
88
88
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fizx-rwget
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.2
4
+ version: 0.5.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kyle Maxwell
@@ -43,7 +43,7 @@ dependencies:
43
43
  version: 0.3.1
44
44
  version:
45
45
  - !ruby/object:Gem::Dependency
46
- name: bloomfilter
46
+ name: igrigorik-bloomfilter
47
47
  type: :runtime
48
48
  version_requirement:
49
49
  version_requirements: !ruby/object:Gem::Requirement