geocoder-us 1.1.0 → 1.1.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,10 @@
1
+ = 1.1.1
2
+
3
+ * Using rc-rest 2.0.0
4
+
5
+ = 1.1.0
6
+
7
+ = 1.0.0
8
+
9
+ * Birthday!
10
+
File without changes
@@ -1,6 +1,7 @@
1
- LICENSE
1
+ History.txt
2
+ LICENSE.txt
2
3
  Manifest.txt
3
- README
4
+ README.txt
4
5
  Rakefile
5
6
  lib/geocoder_us.rb
6
7
  test/test_geocoder_us.rb
File without changes
data/Rakefile CHANGED
@@ -1,68 +1,27 @@
1
- require 'rubygems'
2
- require 'rake'
3
- require 'rake/testtask'
4
- require 'rake/rdoctask'
5
- require 'rake/gempackagetask'
1
+ require 'hoe'
6
2
 
7
- $VERBOSE = nil
3
+ require './lib/geocoder_us'
8
4
 
9
- spec = Gem::Specification.new do |s|
10
- s.name = 'geocoder-us'
11
- s.version = '1.1.0'
12
- s.summary = 'Geocoder.us API Library'
13
- s.description = 'Map addresses to latitude and longitude using geocoder.us'
14
- s.author = 'Eric Hodel'
15
- s.email = 'eric@robotcoop.com'
5
+ DEV_DOC_PATH = 'Libraries/geocoder-us'
16
6
 
17
- s.has_rdoc = true
18
- s.files = File.read('Manifest.txt').split($/)
19
- s.require_path = 'lib'
7
+ hoe = Hoe.new 'geocoder-us', GeocoderUs::VERSION do |p|
8
+ p.summary = 'Geocoder.us API Library'
9
+ p.description = 'Map addresses to latitude and longitude using geocoder.us'
10
+ p.author = 'Eric Hodel'
11
+ p.email = 'drbrain@segment7.net'
12
+ p.url = "http://dev.robotcoop.com/#{DEV_DOC_PATH}"
13
+ p.changes = File.read('History.txt').scan(/\A(=.*?)^=/m).first.first
14
+ p.rubyforge_name = 'rctools'
20
15
 
21
- s.add_dependency 'rc-rest', '>= 1.0.0'
16
+ p.extra_deps << ['rc-rest', '>= 2.0.0']
22
17
  end
23
18
 
24
- desc 'Run tests'
25
- task :default => [ :test ]
19
+ SPEC = hoe.spec
26
20
 
27
- Rake::TestTask.new('test') do |t|
28
- t.libs << '../rc-rest/lib'
29
- t.pattern = 'test/test_*.rb'
30
- t.verbose = true
21
+ begin
22
+ require '../tasks'
23
+ rescue LoadError
31
24
  end
32
25
 
33
- desc 'Update Manifest.txt'
34
- task :update_manifest do
35
- sh "find . -type f | sed -e 's%./%%' | egrep -v 'svn|swp|~' | egrep -v '^(doc|pkg)/' | sort > Manifest.txt"
36
- end
37
-
38
- desc 'Generate RDoc'
39
- Rake::RDocTask.new :rdoc do |rd|
40
- rd.rdoc_dir = 'doc'
41
- rd.rdoc_files.add 'lib', 'README', 'LICENSE'
42
- rd.main = 'README'
43
- rd.options << '-d' if `which dot` =~ /\/dot/
44
- rd.options << '-t Geocoder.us'
45
- end
46
-
47
- desc 'Generate RDoc for dev.robotcoop.com'
48
- Rake::RDocTask.new :dev_rdoc do |rd|
49
- rd.rdoc_dir = '../../../www/trunk/dev/html/Libraries/geocoder-us'
50
- rd.rdoc_files.add 'lib', 'README', 'LICENSE'
51
- rd.main = 'README'
52
- rd.options << '-d' if `which dot` =~ /\/dot/
53
- rd.options << '-t Geocoder.us'
54
- end
55
-
56
- desc 'Build Gem'
57
- Rake::GemPackageTask.new spec do |pkg|
58
- pkg.need_tar = true
59
- end
60
-
61
- desc 'Clean up'
62
- task :clean => [ :clobber_rdoc, :clobber_package ]
63
-
64
- desc 'Clean up'
65
- task :clobber => [ :clean ]
66
-
67
26
  # vim: syntax=Ruby
68
27
 
@@ -7,6 +7,8 @@ require 'rc_rest'
7
7
 
8
8
  class GeocoderUs < RCRest
9
9
 
10
+ VERSION = '1.1.1'
11
+
10
12
  Location = Struct.new :latitude, :longitude, :address
11
13
 
12
14
  ##
@@ -34,11 +36,11 @@ class GeocoderUs < RCRest
34
36
 
35
37
  def initialize(user = nil, password = nil)
36
38
  if user and password then
37
- @url = URI.parse 'http://geocoder.us/member/service/rest/geocode'
39
+ @url = URI.parse 'http://geocoder.us/member/service/rest/'
38
40
  @url.user = user
39
41
  @url.password = password
40
42
  else
41
- @url = URI.parse 'http://rpc.geocoder.us/service/rest/geocode'
43
+ @url = URI.parse 'http://rpc.geocoder.us/service/rest/'
42
44
  end
43
45
  end
44
46
 
@@ -47,7 +49,7 @@ class GeocoderUs < RCRest
47
49
  # raises an AddressError.
48
50
 
49
51
  def locate(address)
50
- get :address => address
52
+ get :geocode, :address => address
51
53
  end
52
54
 
53
55
  def parse_response(xml)
@@ -1,4 +1,5 @@
1
1
  require 'test/unit'
2
+ require 'rubygems'
2
3
  require 'rc_rest/uri_stub'
3
4
  require 'geocoder_us'
4
5
 
metadata CHANGED
@@ -1,16 +1,16 @@
1
1
  --- !ruby/object:Gem::Specification
2
- rubygems_version: 0.8.99
2
+ rubygems_version: 0.9.0.6
3
3
  specification_version: 1
4
4
  name: geocoder-us
5
5
  version: !ruby/object:Gem::Version
6
- version: 1.1.0
7
- date: 2006-06-16 00:00:00 -07:00
6
+ version: 1.1.1
7
+ date: 2006-11-27 00:00:00 -08:00
8
8
  summary: Geocoder.us API Library
9
9
  require_paths:
10
10
  - lib
11
- email: eric@robotcoop.com
12
- homepage:
13
- rubyforge_project:
11
+ email: drbrain@segment7.net
12
+ homepage: http://dev.robotcoop.com/Libraries/geocoder-us
13
+ rubyforge_project: rctools
14
14
  description: Map addresses to latitude and longitude using geocoder.us
15
15
  autorequire:
16
16
  default_executable:
@@ -29,14 +29,15 @@ post_install_message:
29
29
  authors:
30
30
  - Eric Hodel
31
31
  files:
32
- - LICENSE
32
+ - History.txt
33
+ - LICENSE.txt
33
34
  - Manifest.txt
34
- - README
35
+ - README.txt
35
36
  - Rakefile
36
37
  - lib/geocoder_us.rb
37
38
  - test/test_geocoder_us.rb
38
- test_files: []
39
-
39
+ test_files:
40
+ - test/test_geocoder_us.rb
40
41
  rdoc_options: []
41
42
 
42
43
  extra_rdoc_files: []
@@ -48,6 +49,15 @@ extensions: []
48
49
  requirements: []
49
50
 
50
51
  dependencies:
52
+ - !ruby/object:Gem::Dependency
53
+ name: hoe
54
+ version_requirement:
55
+ version_requirements: !ruby/object:Gem::Version::Requirement
56
+ requirements:
57
+ - - ">="
58
+ - !ruby/object:Gem::Version
59
+ version: 1.1.4
60
+ version:
51
61
  - !ruby/object:Gem::Dependency
52
62
  name: rc-rest
53
63
  version_requirement:
@@ -55,5 +65,5 @@ dependencies:
55
65
  requirements:
56
66
  - - ">="
57
67
  - !ruby/object:Gem::Version
58
- version: 1.0.0
68
+ version: 2.0.0
59
69
  version: