autometal-geoip 0.3.3 → 0.3.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. data/autometal-geoip.gemspec +1 -1
  2. data/lib/geoip.rb +3 -3
  3. metadata +4 -4
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = %q{autometal-geoip}
5
- s.version = "0.3.1"
5
+ s.version = "0.3.4"
6
6
 
7
7
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
8
8
  s.authors = ["Achillefs Charmpilas"]
@@ -3,7 +3,7 @@ $:.unshift(File.dirname(__FILE__)) unless
3
3
 
4
4
  module Autometal
5
5
  class Geoip
6
- VERSION = '0.3.3'
6
+ VERSION = '0.3.4'
7
7
  DATA_FILE_PATH = "/usr/local/share/GeoIP/"
8
8
  BIN = "geoiplookup"
9
9
  def initialize ip_or_domain
@@ -17,7 +17,7 @@ module Autometal
17
17
  end
18
18
 
19
19
  def self.bin_installed?
20
- %x{ #{self::BIN} --version } == "" ? false : true
20
+ File.exists?(%x{ which #{self::BIN} }.strip)
21
21
  end
22
22
  =begin rdoc
23
23
  Extensible class that uses the Geoip binaries and data files to geolocate IPs and Hostnames.
@@ -54,4 +54,4 @@ module Autometal
54
54
  end
55
55
  end
56
56
 
57
- %W[installer geolocatable city organization].each { |r| require "#{File.dirname(__FILE__)}/geoip/#{r}" }
57
+ %W[installer geolocatable city organization].each { |r| require "#{File.dirname(__FILE__)}/geoip/#{r}" }
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: autometal-geoip
3
3
  version: !ruby/object:Gem::Version
4
- hash: 21
4
+ hash: 27
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 3
9
- - 3
10
- version: 0.3.3
9
+ - 4
10
+ version: 0.3.4
11
11
  platform: ruby
12
12
  authors:
13
13
  - Achillefs Charmpilas
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2010-12-08 00:00:00 +01:00
18
+ date: 2010-12-25 00:00:00 +01:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency