geonames_local 3.3.4 → 3.3.5

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 0ba4f5b249b265786ed141a7cb788ecbbdb8d972
4
- data.tar.gz: 5c72a80db053d42786b373207892e353ccac08d9
3
+ metadata.gz: da5c0c1a8841c94f035f463c9b4a6fbc91c50a26
4
+ data.tar.gz: e0231199f092bd5e880a8763a1af4364f813207b
5
5
  SHA512:
6
- metadata.gz: 5be133df0fde1cc8b007d7b4369d497b2b1e012fe234d7a2ae7c250433b98dfea5fdec5fd434c91c7ab1da33983ee46f5d1b58775eed08907a18ec3404f9c6c4
7
- data.tar.gz: cf0e1a0d83460d355a70b7edf7fdd95c9c13c700502a5c08404d7cca4afcbfb637a3e9d014b0f5df55ba7880cd129788a99ece4bc8701b1382df698a914371b9
6
+ metadata.gz: b9529b8e58f50aba28e2195d60fb2dbddbe7af22dc3b10a6669c78c96125c1dc196f94936bb27ba9eddd461b222e787446092a109d696f01aabbe6a85a1df5cc
7
+ data.tar.gz: a0eff671aff5a468b1c212b4a89adb259086b327a89d2b12ad31bfb6bc8f1a37a5139aaacc43abf4cd1593cfd459af79eeed871fa994ddce37344734351c03ee
data/README.md CHANGED
@@ -3,7 +3,12 @@ Geonames Local
3
3
 
4
4
  Downloads and store Geonames.org data locally (MongoDB, Mongoid).
5
5
  Making every Geoname API operation possible on your servers.
6
- No hit limit, fast as possible.
6
+ **No hit limit, fast as possible.**
7
+
8
+
9
+ * Download all country data
10
+ * Merges ZIP into cities, so you have masks
11
+ * Updates using geonames IDs, no duplication
7
12
 
8
13
 
9
14
  Use
@@ -74,8 +74,8 @@ module Geonames
74
74
  nation = Nation.find_by(abbr: /#{r.nation}/i)
75
75
  info "Region: #{r.name} / #{r.abbr}"
76
76
  {
77
+ id: r.gid.to_s, abbr: r.abbr,
77
78
  name_translations: translate(r.name),
78
- gid: r.gid, abbr: r.abbr,
79
79
  nation: nation, code: r.region
80
80
  }
81
81
  end
@@ -89,10 +89,10 @@ module Geonames
89
89
  # info s.inspect
90
90
  info "City: #{s.zip} | #{s.name} / #{region.try(:abbr)}"
91
91
  {
92
+ id: s.gid.to_s, code: s.code,
92
93
  name_translations: translate(s.name),
93
- gid: s.gid, code: s.code,
94
94
  souls: s.pop, geom: [s.lon, s.lat],
95
- region: region, postal: s.zip # tz
95
+ region_id: region.id.to_s, postal: s.zip # tz
96
96
  }
97
97
  end
98
98
  end
@@ -1,3 +1,3 @@
1
1
  module Geonames
2
- VERSION = '3.3.4'
2
+ VERSION = '3.3.5'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: geonames_local
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.3.4
4
+ version: 3.3.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Marcos Piccinini
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-07-17 00:00:00.000000000 Z
11
+ date: 2015-08-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: mongoid
@@ -117,7 +117,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
117
117
  version: '0'
118
118
  requirements: []
119
119
  rubyforge_project:
120
- rubygems_version: 2.4.7
120
+ rubygems_version: 2.4.5
121
121
  signing_key:
122
122
  specification_version: 4
123
123
  summary: Dumps geonames data for local usage