countries 4.1.1 → 4.1.2

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.
Files changed (128) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +12 -4
  3. data/README.markdown +8 -12
  4. data/countries.gemspec +1 -1
  5. data/lib/countries/cache/countries.json +1 -1
  6. data/lib/countries/cache/locales/ab.json +1 -1
  7. data/lib/countries/cache/locales/af.json +1 -1
  8. data/lib/countries/cache/locales/ak.json +1 -1
  9. data/lib/countries/cache/locales/am.json +1 -1
  10. data/lib/countries/cache/locales/an.json +1 -1
  11. data/lib/countries/cache/locales/as.json +1 -1
  12. data/lib/countries/cache/locales/ay.json +1 -1
  13. data/lib/countries/cache/locales/az.json +1 -1
  14. data/lib/countries/cache/locales/ba.json +1 -1
  15. data/lib/countries/cache/locales/bg.json +1 -1
  16. data/lib/countries/cache/locales/bi.json +1 -1
  17. data/lib/countries/cache/locales/br.json +1 -1
  18. data/lib/countries/cache/locales/bs.json +1 -1
  19. data/lib/countries/cache/locales/ca.json +1 -1
  20. data/lib/countries/cache/locales/ce.json +1 -1
  21. data/lib/countries/cache/locales/ch.json +1 -1
  22. data/lib/countries/cache/locales/cv.json +1 -1
  23. data/lib/countries/cache/locales/de.json +1 -1
  24. data/lib/countries/cache/locales/dv.json +1 -1
  25. data/lib/countries/cache/locales/dz.json +1 -1
  26. data/lib/countries/cache/locales/ee.json +1 -1
  27. data/lib/countries/cache/locales/en.json +1 -1
  28. data/lib/countries/cache/locales/eo.json +1 -1
  29. data/lib/countries/cache/locales/es.json +1 -1
  30. data/lib/countries/cache/locales/et.json +1 -1
  31. data/lib/countries/cache/locales/ff.json +1 -1
  32. data/lib/countries/cache/locales/fi.json +1 -1
  33. data/lib/countries/cache/locales/fo.json +1 -1
  34. data/lib/countries/cache/locales/fr.json +1 -1
  35. data/lib/countries/cache/locales/fy.json +1 -1
  36. data/lib/countries/cache/locales/ga.json +1 -1
  37. data/lib/countries/cache/locales/gl.json +1 -1
  38. data/lib/countries/cache/locales/gn.json +1 -1
  39. data/lib/countries/cache/locales/gu.json +1 -1
  40. data/lib/countries/cache/locales/gv.json +1 -1
  41. data/lib/countries/cache/locales/ha.json +1 -1
  42. data/lib/countries/cache/locales/he.json +1 -1
  43. data/lib/countries/cache/locales/hi.json +1 -1
  44. data/lib/countries/cache/locales/hr.json +1 -1
  45. data/lib/countries/cache/locales/ht.json +1 -1
  46. data/lib/countries/cache/locales/hy.json +1 -1
  47. data/lib/countries/cache/locales/io.json +1 -1
  48. data/lib/countries/cache/locales/is.json +1 -1
  49. data/lib/countries/cache/locales/iu.json +1 -1
  50. data/lib/countries/cache/locales/ja.json +1 -1
  51. data/lib/countries/cache/locales/ka.json +1 -1
  52. data/lib/countries/cache/locales/ki.json +1 -1
  53. data/lib/countries/cache/locales/kk.json +1 -1
  54. data/lib/countries/cache/locales/kl.json +1 -1
  55. data/lib/countries/cache/locales/km.json +1 -1
  56. data/lib/countries/cache/locales/kn.json +1 -1
  57. data/lib/countries/cache/locales/kv.json +1 -1
  58. data/lib/countries/cache/locales/kw.json +1 -1
  59. data/lib/countries/cache/locales/ky.json +1 -1
  60. data/lib/countries/cache/locales/lo.json +1 -1
  61. data/lib/countries/cache/locales/lt.json +1 -1
  62. data/lib/countries/cache/locales/lv.json +1 -1
  63. data/lib/countries/cache/locales/mi.json +1 -1
  64. data/lib/countries/cache/locales/mk.json +1 -1
  65. data/lib/countries/cache/locales/ml.json +1 -1
  66. data/lib/countries/cache/locales/mn.json +1 -1
  67. data/lib/countries/cache/locales/ms.json +1 -1
  68. data/lib/countries/cache/locales/mt.json +1 -1
  69. data/lib/countries/cache/locales/my.json +1 -1
  70. data/lib/countries/cache/locales/na.json +1 -1
  71. data/lib/countries/cache/locales/nb.json +1 -1
  72. data/lib/countries/cache/locales/ne.json +1 -1
  73. data/lib/countries/cache/locales/nl.json +1 -1
  74. data/lib/countries/cache/locales/nn.json +1 -1
  75. data/lib/countries/cache/locales/nv.json +1 -1
  76. data/lib/countries/cache/locales/oc.json +1 -1
  77. data/lib/countries/cache/locales/pi.json +1 -1
  78. data/lib/countries/cache/locales/ps.json +1 -1
  79. data/lib/countries/cache/locales/pt-br.json +1 -1
  80. data/lib/countries/cache/locales/ro.json +1 -1
  81. data/lib/countries/cache/locales/ru.json +1 -1
  82. data/lib/countries/cache/locales/rw.json +1 -1
  83. data/lib/countries/cache/locales/sc.json +1 -1
  84. data/lib/countries/cache/locales/sd.json +1 -1
  85. data/lib/countries/cache/locales/si.json +1 -1
  86. data/lib/countries/cache/locales/sk.json +1 -1
  87. data/lib/countries/cache/locales/sl.json +1 -1
  88. data/lib/countries/cache/locales/so.json +1 -1
  89. data/lib/countries/cache/locales/sr.json +1 -1
  90. data/lib/countries/cache/locales/sv.json +1 -1
  91. data/lib/countries/cache/locales/sw.json +1 -1
  92. data/lib/countries/cache/locales/ta.json +1 -1
  93. data/lib/countries/cache/locales/te.json +1 -1
  94. data/lib/countries/cache/locales/th.json +1 -1
  95. data/lib/countries/cache/locales/ti.json +1 -1
  96. data/lib/countries/cache/locales/tk.json +1 -1
  97. data/lib/countries/cache/locales/tl.json +1 -1
  98. data/lib/countries/cache/locales/tr.json +1 -1
  99. data/lib/countries/cache/locales/tt.json +1 -1
  100. data/lib/countries/cache/locales/ur.json +1 -1
  101. data/lib/countries/cache/locales/uz.json +1 -1
  102. data/lib/countries/cache/locales/ve.json +1 -1
  103. data/lib/countries/cache/locales/vi.json +1 -1
  104. data/lib/countries/cache/locales/wa.json +1 -1
  105. data/lib/countries/cache/locales/wo.json +1 -1
  106. data/lib/countries/cache/locales/xh.json +1 -1
  107. data/lib/countries/cache/locales/yo.json +1 -1
  108. data/lib/countries/cache/locales/zh-cn.json +1 -1
  109. data/lib/countries/cache/locales/zh.json +1 -1
  110. data/lib/countries/cache/locales/zu.json +1 -1
  111. data/lib/countries/data/countries/SZ.yaml +1 -1
  112. data/lib/countries/data/subdivisions/CZ.yaml +951 -3707
  113. data/lib/countries/data/subdivisions/DE.yaml +16 -16
  114. data/lib/countries/data/subdivisions/DK.yaml +65 -287
  115. data/lib/countries/data/subdivisions/EE.yaml +96 -88
  116. data/lib/countries/data/subdivisions/FI.yaml +102 -499
  117. data/lib/countries/data/subdivisions/FR.yaml +584 -977
  118. data/lib/countries/data/subdivisions/GR.yaml +117 -988
  119. data/lib/countries/data/subdivisions/HU.yaml +62 -62
  120. data/lib/countries/data/subdivisions/IE.yaml +483 -482
  121. data/lib/countries/data/subdivisions/IT.yaml +1251 -1839
  122. data/lib/countries/data/subdivisions/LU.yaml +194 -243
  123. data/lib/countries/data/subdivisions/LV.yaml +144 -5142
  124. data/lib/countries/data/subdivisions/NZ.yaml +67 -111
  125. data/lib/countries/data/subdivisions/PL.yaml +210 -1208
  126. data/lib/countries/data/translation_corrections.yaml +3 -1
  127. data/lib/countries/version.rb +1 -1
  128. metadata +4 -4
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e92774738bb8bd03ce6ea03faefddf5318b166e40c1997d09ace3fa417abba8c
4
- data.tar.gz: 1f3e6c44fd8db1865d362e3d8e07a6238fbcf717daeea404a1c3c7dab71d5829
3
+ metadata.gz: d7fef1ba0b30d18c6653eb178c2a69c32d42d53e5d21418ed2ead00c94a5ed9c
4
+ data.tar.gz: c2160c97c50d1994ee1520607eeff6413bf4ccabe0aa51b82f7e94dec8c25fa2
5
5
  SHA512:
6
- metadata.gz: f7ce86dd2a2aec4463d27b07c427a3ea6fa097d04661343b9309a603a52c5ab3dcbaff6f50dcb4c19ce9bdd373f144dc718f7409bdcdde83811395b341b39625
7
- data.tar.gz: adb4cbf79ae7da1315810ec6aaf55c71f9a7d6c0d9d99743fc32cd686db63fe5157523b22aedcc425abf3576e3e99ec5af7e9d19655df4562deb8f055029bbb7
6
+ metadata.gz: 4cbc87e4f7c70926939546cdd1bea00f081b135d9063d35c95b9fe4eb372be6fba5231297869e457b82d28c3e232eddde736d497624c2477d837d49d0e55c15d
7
+ data.tar.gz: 9de3121086005ae9b98dedb25774e6505d5955db69ef3239ce866c8fe0e4383481bfc2bcc0ab247cecc2f6ad9974c80a8b948b37174cd1c42e1c5f1356cd5a87
data/CHANGELOG.md CHANGED
@@ -2,16 +2,24 @@
2
2
  All notable changes to this project will be documented in this file.
3
3
  This project adheres to [Semantic Versioning](http://semver.org/).
4
4
 
5
- ## [Unreleased]
5
+ ## [Future 5.0 release]
6
6
 
7
- - Dropped support for Ruby 2.5
7
+ - Drop support for Ruby 2.5 [\#708](https://github.com/countries/countries/pull/708) ([pmor](https://github.com/pmor))
8
+
9
+ ## [4.1.2](https://github.com/countries/countries/releases/tag/v4.1.2) (2021/12/20 17:06 +00:00)
10
+
11
+ * Update subdivisions, fix #600 conflicts [\#710](https://github.com/countries/countries/pull/710) ([donnen](https://github.com/donnen), [pmor](https://github.com/pmor))
12
+ * Fix conflicts in #605 and update those countries to the latest subdivision data [\#711](https://github.com/countries/countries/pull/711) ([jjamesjohnson](https://github.com/jjamesjohnson), [pmor](https://github.com/pmor))
13
+ * Update NZ subdivision data and fix Chatham Island entry [\#712](https://github.com/countries/countries/pull/712) ([pmor](https://github.com/pmor))
14
+ * Update translation corrections for Occitan.[\#713](https://github.com/countries/countries/pull/713) ([pmor](https://github.com/pmor))
15
+ * Update i18n_data to 0.15.0 [\#715](https://github.com/countries/countries/pull/715) ([pmor](https://github.com/pmor))
8
16
 
9
17
  ## [4.1.1](https://github.com/countries/countries/releases/tag/v4.1.1) (2021/12/06 13:31 +00:00)
10
18
 
11
19
  **Merged pull requests:**
12
20
 
13
- * Fix ISO3166::Country respond_to_missing? by @biinari in https://github.com/countries/countries/pull/625
14
- * Revert subdivision changes to NO.yaml by @pmor in https://github.com/countries/countries/pull/709
21
+ * Fix ISO3166::Country respond_to_missing? [\#625](https://github.com/countries/countries/pull/625) ([biinari](https://github.com/biinari))
22
+ * Revert subdivision changes to NO.yaml [\#709](https://github.com/countries/countries/pull/709) ([pmor](https://github.com/pmor))
15
23
 
16
24
  ## [4.1.0](https://github.com/countries/countries/releases/tag/v4.1.0) (2021/11/30 09:44 +00:00)
17
25
 
data/README.markdown CHANGED
@@ -48,20 +48,15 @@ To Use
48
48
  gem 'countries', require: 'countries/global'
49
49
  ```
50
50
 
51
- ## Upgrading to 3.x
51
+ ## Upgrading to 4.2 and 5.x
52
52
 
53
- We dropped currency support via money by default, read these [instructions](README.markdown#Currencies) if you are using currency features.
53
+ In release 4.2 the `#name` attribute was deprecated in favour of `#iso_short_name` and we added `#iso_long_name`, to make it clear that these attributes use the ISO3166 names, and are not the "common names" most people might expect, eg: The ISO name for "United Kingdom" is "United Kingdom of Great Britain and Northern Ireland", but if you're building a dropdown box to select a country, you're likely expecting to see "United Kingdom" instead.
54
54
 
55
- ## Upgrading Country Helper to > 1.2.0
55
+ The `#name` attribute will be removed in 5.0.
56
+
57
+ For translated country names, we use data from [pkg-isocodes](https://salsa.debian.org/iso-codes-team/iso-codes), via the [i18n_data](https://github.com/grosser/i18n_data) gem, and these generally correspond to the expected "common names". These names and the corresponding methods have not been changed.
56
58
 
57
- ```ruby
58
- gem 'countries', require: 'global'
59
- ```
60
59
 
61
- has become
62
- ```ruby
63
- gem 'countries', require: 'countries/global'
64
- ```
65
60
 
66
61
  ## Selective Loading of Locales
67
62
 
@@ -112,7 +107,8 @@ c.gec # => "US"
112
107
  ### Names & Translations
113
108
 
114
109
  ```ruby
115
- c.name # => "United States"
110
+ c.iso_long_name # => "The United States of America"
111
+ c.iso_short_name # => "United States of America"
116
112
  c.unofficial_names # => ["United States of America", "Vereinigte Staaten von Amerika", "États-Unis", "Estados Unidos"]
117
113
 
118
114
  # Get the names for a country translated to its local languages
@@ -318,7 +314,7 @@ c.emoji_flag # => "🇲🇾"
318
314
 
319
315
  Any additions should be directed upstream to [pkg-isocodes](https://salsa.debian.org/iso-codes-team/iso-codes)
320
316
 
321
- New Bugs can be filed upstream here https://salsa.debian.org/iso-codes-team/iso-codes/issues
317
+ Localized country name data is sourced from https://github.com/grosser/i18n_data (which is based on https://salsa.debian.org/iso-codes-team/iso-codes/). Issues regarding localized country names can be reported to https://github.com/grosser/i18n_data/issues or https://salsa.debian.org/iso-codes-team/iso-codes/issues
322
318
  If you need to correct an upstream translation please add it to the lib/countries/data/translations_corrections.yaml
323
319
 
324
320
  ```
data/countries.gemspec CHANGED
@@ -21,7 +21,7 @@ Gem::Specification.new do |gem|
21
21
 
22
22
  gem.required_ruby_version = '>= 2.5'
23
23
 
24
- gem.add_dependency('i18n_data', '~> 0.13.1')
24
+ gem.add_dependency('i18n_data', '~> 0.15.0')
25
25
  gem.add_dependency('sixarm_ruby_unaccent', '~> 1.1')
26
26
  gem.add_development_dependency('rspec', '>= 3')
27
27
  gem.add_development_dependency('activesupport', '>= 3')