simple-countries 0.1.2 → 0.1.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 7f48a760cfb01e1677ef635e9d8591bd299ec637
4
- data.tar.gz: 79dc71ca74fdb4f83c7d3ed1887817f62b1242a8
3
+ metadata.gz: 5b9d1eed0be4eff91f3e3fef10471b587729305a
4
+ data.tar.gz: e1f16a3fb5f701aaa0def9a92b2aa68a065093b2
5
5
  SHA512:
6
- metadata.gz: 2f662808867733868c21e550cad8183c19060529e7fd9f2828e3eb52836f903b41e6752e895c7cb673b53c94db6f5af87f518bba02bcf19492a8e34670867c12
7
- data.tar.gz: b0f405cef6b1f06ee0b299cc1679348b2daf5d885994612bb701f2877f78422f6d1845fa83c2ec3491ad3b6f6322d8b9bc6dc420f398fe1d2711a8099868f13d
6
+ metadata.gz: 816a52a5de8c93f7d3a758bd9d15b0246db8efec0459e429ef543f05ad1a8a8adb7ea1f13fb93f295dd99c3c6fbfb747b7a47cb648b9d5027d14b3b4fb2d2b2c
7
+ data.tar.gz: 6bb5a8b4bb5b6d4dcfbd16ae3e26a79f64772020cdd97e541a6b0e210d56ae48e5782f4008735b528f16741f0d6ef126a381c6d4919a477068975650609d91cd
@@ -1,5 +1,5 @@
1
1
  sudo: false
2
2
  language: ruby
3
3
  rvm:
4
- - 2.2.1
4
+ - 2.3.1
5
5
  before_install: gem install bundler -v 1.12.5
data/Gemfile CHANGED
@@ -3,3 +3,4 @@ source 'https://rubygems.org'
3
3
  # Specify your gem's dependencies in simple-countries.gemspec
4
4
  gemspec
5
5
  gem 'city-state'
6
+ gem 'activesupport', '~> 4.2', '>= 4.2.6'
data/README.md CHANGED
@@ -19,16 +19,19 @@ Or install it yourself as:
19
19
 
20
20
  ## Usage
21
21
  Simple Method :
22
+ You can use `` Simple::Countries `` or `` Countries ``
22
23
 
23
24
  - Get All
24
25
 
25
26
  ```ruby
26
27
  Simple::Countries.all
28
+ Countries.all
27
29
  ```
28
30
  - Find
29
31
 
30
32
  ```ruby
31
33
  Simple::Countries.find(2)
34
+ Countries.find(2)
32
35
  ```
33
36
  return `` {:id=>2, :alias=>"AL", :name=>"Albania"} ``
34
37
 
@@ -36,6 +39,7 @@ Simple Method :
36
39
 
37
40
  ```ruby
38
41
  Simple::Countries.first
42
+ Countries.first
39
43
  ```
40
44
  return `` {:id=>1, :alias=>"AF", :name=>"Afghanistan"} ``
41
45
 
@@ -43,6 +47,7 @@ Simple Method :
43
47
 
44
48
  ```ruby
45
49
  Simple::Countries.last
50
+ Countries.last
46
51
  ```
47
52
  return `` {:id=>241, :alias=>"ZW", :name=>"Zimbabwe"} ``
48
53
 
@@ -50,6 +55,7 @@ Simple Method :
50
55
 
51
56
  ```ruby
52
57
  Simple::Countries.find_by_alias('AF')
58
+ Countries.find_by_alias('AF')
53
59
  ```
54
60
  return `` Afghanistan ``
55
61
 
@@ -57,6 +63,7 @@ Simple Method :
57
63
 
58
64
  ```ruby
59
65
  Simple::Countries.search('A')
66
+ Countries.search('A')
60
67
  ```
61
68
  return a array :
62
69
  ```ruby
@@ -67,6 +74,7 @@ Simple Method :
67
74
 
68
75
  ```ruby
69
76
  Simple::Countries.search_by_key('A')
77
+ Countries.search_by_key('A')
70
78
  ```
71
79
  return a array :
72
80
 
@@ -78,11 +86,13 @@ Simple Method :
78
86
 
79
87
  ```ruby
80
88
  Simple::Countries.has_key?('wf')
89
+ Countries.has_key?('wf')
81
90
  ```
82
91
  return `` false ``
83
92
 
84
93
  ```ruby
85
94
  Simple::Countries.has_key?('WF')
95
+ Countries.has_key?('WF')
86
96
  ```
87
97
  return `` true ``
88
98
 
@@ -90,6 +100,7 @@ Simple Method :
90
100
 
91
101
  ```ruby
92
102
  Simple::Countries.alias
103
+ Countries.alias
93
104
  ```
94
105
  return array of alias
95
106
 
@@ -101,6 +112,7 @@ Simple Method :
101
112
 
102
113
  ```ruby
103
114
  Simple::Countries.name
115
+ Countries.name
104
116
  ```
105
117
  return a array of name
106
118
 
@@ -108,10 +120,68 @@ Simple Method :
108
120
  ["Afghanistan", "Albania", "Algeria", "American Samoa", "Andorra", "Angola", "Anguilla", "Antarctica", "Antigua And Barbuda", "Argentina", "Armenia", "Aruba", "Australia", "Austria", "Azerbaijan", "Bahamas", "Bahrain", "Bangladesh", "Barbados", "Belarus", "Belgium", "Belize", "Benin", "Bermuda", "Bhutan", "Bolivia", "Bosnia And Herzegovina", "Botswana", "Bouvet Island", "Brazil", "British Indian Ocean Territory", "Brunei Darussalam", "Bulgaria", "Burkina Faso", "Burundi", "Cambodia", "Cameroon", "Canada", "Cape Verde", "Cayman Islands", "Central African Republic", "Chad", "Chile", "China", "Christmas Island", "Cocos (keeling) Islands", "Colombia", "Comoros", "Congo", "Congo, The Democratic Republic Of The", "Cook Islands", "Costa Rica", "Cote D'ivoire", "Croatia", "Cuba", "Cyprus", "Czech Republic", "Denmark", "Djibouti", "Dominica", "Dominican Republic", "East Timor", "Ecuador", "Egypt", "El Salvador", "Equatorial Guinea", "Eritrea", "Estonia", "Ethiopia", "Falkland Islands (malvinas)", "Faroe Islands", "Fiji", "Finland", "France", "French Guiana", "French Polynesia", "French Southern Territories", "Gabon", "Gambia", "Georgia", "Germany", "Ghana", "Gibraltar", "Greece", "Greenland", "Grenada", "Guadeloupe", "Guam", "Guatemala", "Guinea", "Guinea-bissau", "Guyana", "Haiti", "Heard Island And Mcdonald Islands", "Holy See (vatican City State)", "Honduras", "Hong Kong", "Hungary", "Iceland", "India", "Indonesia", "Iran, Islamic Republic Of", "Iraq", "Ireland", "Israel", "Italy", "Jamaica", "Japan", "Jordan", "Kazakstan", "Kenya", "Kiribati", "Korea, Democratic People's Republic Of", "Korea, Republic Of", "Kosovo", "Kuwait", "Kyrgyzstan", "Lao People's Democratic Republic", "Latvia", "Lebanon", "Lesotho", "Liberia", "Libyan Arab Jamahiriya", "Liechtenstein", "Lithuania", "Luxembourg", "Macau", "Macedonia, The Former Yugoslav Republic Of", "Madagascar", "Malawi", "Malaysia", "Maldives", "Mali", "Malta", "Marshall Islands", "Martinique", "Mauritania", "Mauritius", "Mayotte", "Mexico", "Micronesia, Federated States Of", "Moldova, Republic Of", "Monaco", "Mongolia", "Montserrat", "Montenegro", "Morocco", "Mozambique", "Myanmar", "Namibia", "Nauru", "Nepal", "Netherlands", "Netherlands Antilles", "New Caledonia", "New Zealand", "Nicaragua", "Niger", "Nigeria", "Niue", "Norfolk Island", "Northern Mariana Islands", "Norway", "Oman", "Pakistan", "Palau", "Palestinian Territory, Occupied", "Panama", "Papua New Guinea", "Paraguay", "Peru", "Philippines", "Pitcairn", "Poland", "Portugal", "Puerto Rico", "Qatar", "Reunion", "Romania", "Russian Federation", "Rwanda", "Saint Helena", "Saint Kitts And Nevis", "Saint Lucia", "Saint Pierre And Miquelon", "Saint Vincent And The Grenadines", "Samoa", "San Marino", "Sao Tome And Principe", "Saudi Arabia", "Senegal", "Serbia", "Seychelles", "Sierra Leone", "Singapore", "Slovakia", "Slovenia", "Solomon Islands", "Somalia", "South Africa", "South Georgia And The South Sandwich Islands", "Spain", "Sri Lanka", "Sudan", "Suriname", "Svalbard And Jan Mayen", "Swaziland", "Sweden", "Switzerland", "Syrian Arab Republic", "Taiwan, Province Of China", "Tajikistan", "Tanzania, United Republic Of", "Thailand", "Togo", "Tokelau", "Tonga", "Trinidad And Tobago", "Tunisia", "Turkey", "Turkmenistan", "Turks And Caicos Islands", "Tuvalu", "Uganda", "Ukraine", "United Arab Emirates", "United Kingdom", "United States", "United States Minor Outlying Islands", "Uruguay", "Uzbekistan", "Vanuatu", "Venezuela", "Viet Nam", "Virgin Islands, British", "Virgin Islands, U.s.", "Wallis And Futuna", "Western Sahara", "Yemen", "Zambia", "Zimbabwe"]
109
121
  ```
110
122
 
123
+ ## New method when use `` Countries ``
124
+
125
+ - Get States in Country
111
126
 
127
+ ```ruby
128
+ Countries.states('us')
129
+ ```
130
+ return a array
131
+
132
+ ```ruby
133
+ {:AK=>"Alaska", :AL=>"Alabama", :AR=>"Arkansas", :AZ=>"Arizona", :CA=>"California", :CO=>"Colorado", :CT=>"Connecticut", :DC=>"District of Columbia", :DE=>"Delaware", :FL=>"Florida", :GA=>"Georgia", :HI=>"Hawaii", :IA=>"Iowa", :ID=>"Idaho", :IL=>"Illinois", :IN=>"Indiana", :KS=>"Kansas", :KY=>"Kentucky", :LA=>"Louisiana", :MA=>"Massachusetts", :MD=>"Maryland", :ME=>"Maine", :MI=>"Michigan", :MN=>"Minnesota", :MO=>"Missouri", :MS=>"Mississippi", :MT=>"Montana", :NC=>"North Carolina", :ND=>"North Dakota", :NE=>"Nebraska", :NH=>"New Hampshire", :NJ=>"New Jersey", :NM=>"New Mexico", :NV=>"Nevada", :NY=>"New York", :OH=>"Ohio", :OK=>"Oklahoma", :OR=>"Oregon", :PA=>"Pennsylvania", :RI=>"Rhode Island", :SC=>"South Carolina", :SD=>"South Dakota", :TN=>"Tennessee", :TX=>"Texas", :UT=>"Utah", :VA=>"Virginia", :VT=>"Vermont", :WA=>"Washington", :WI=>"Wisconsin", :WV=>"West Virginia", :WY=>"Wyoming"}
134
+ ```
135
+
136
+ - Get Cities in State of a coutry
137
+
138
+ ```ruby
139
+ Countries.cities('ak', 'us')
140
+ ```
141
+ return a array
142
+ ```ruby
143
+ ["Adak", "Akhiok", "Akiachak", "Akiak", "Akutan", "Alakanuk", "Ambler", "Anchor Point", "Anchorage", "Angoon", "Atqasuk", "Barrow", "Bethel", "Big Lake", "Buckland", "Chefornak", "Chevak", "Chicken", "Chugiak", "Coffman Cove", "Cooper Landing", "Copper Center", "Cordova", "Craig", "Delta Junction", "Deltana", "Dillingham", "Douglas", "Dutch Harbor", "Eagle River", "Eielson Air Force Base", "Fairbanks", "Fairbanks North Star Borough", "Fort Greely", "Fort Richardson", "Fort Yukon", "Gakona", "Galena", "Girdwood", "Goodnews Bay", "Haines", "Homer", "Hooper Bay", "Juneau", "Kake", "Kaktovik", "Kalskag", "Kaltag", "Kenai", "Ketchikan", "Kiana", "King Cove", "King Salmon", "Kipnuk", "Klawock", "Kodiak", "Kongiganak", "Kotlik", "Kotzebue", "Koyuk", "Kwethluk", "Levelock", "Manokotak", "May Creek", "Mekoryuk", "Metlakatla", "Mountain Village", "Naknek", "Nazan Village", "Nenana", "New Stuyahok", "Nikiski", "Ninilchik", "Noatak", "Nome", "Nondalton", "Noorvik", "North Pole", "Northway", "Nuiqsut", "Old Kotzebue", "Palmer", "Pedro Bay", "Petersburg", "Pilot Station", "Point Hope", "Point Lay", "Prudhoe Bay", "Russian Mission", "Sand Point", "Scammon Bay", "Selawik", "Seward", "Shungnak", "Sitka", "Skaguay", "Soldotna", "Stebbins", "Sterling", "Sutton", "Talkeetna", "Teller", "Thorne Bay", "Togiak", "Tok", "Toksook Bay", "Tuntutuliak", "Two Rivers", "Unalakleet", "Unalaska", "Valdez", "Wainwright", "Wasilla", "Wrangel"]
144
+ ```
145
+ - Get states from custom countires with input is a array ``[]``
146
+
147
+ ```ruby
148
+ Countries.custom_states(['us', 'br'])
149
+ ```
150
+ return a hash
151
+ ```ruby
152
+ {:AK=>"Alaska", :AL=>"Alagoas", :AR=>"Arkansas", :AZ=>"Arizona", :CA=>"California", :CO=>"Colorado", :CT=>"Connecticut", :DC=>"District of Columbia", :DE=>"Delaware", :FL=>"Florida", :GA=>"Georgia", :HI=>"Hawaii", :IA=>"Iowa", :ID=>"Idaho", :IL=>"Illinois", :IN=>"Indiana", :KS=>"Kansas", :KY=>"Kentucky", :LA=>"Louisiana", :MA=>"Maranhao", :MD=>"Maryland", :ME=>"Maine", :MI=>"Michigan", :MN=>"Minnesota", :MO=>"Missouri", :MS=>"Mato Grosso do Sul", :MT=>"Mato Grosso", :NC=>"North Carolina", :ND=>"North Dakota", :NE=>"Nebraska", :NH=>"New Hampshire", :NJ=>"New Jersey", :NM=>"New Mexico", :NV=>"Nevada", :NY=>"New York", :OH=>"Ohio", :OK=>"Oklahoma", :OR=>"Oregon", :PA=>"Para", :RI=>"Rhode Island", :SC=>"Santa Catarina", :SD=>"South Dakota", :TN=>"Tennessee", :TX=>"Texas", :UT=>"Utah", :VA=>"Virginia", :VT=>"Vermont", :WA=>"Washington", :WI=>"Wisconsin", :WV=>"West Virginia", :WY=>"Wyoming", :AC=>"Acre", :AM=>"Amazonas", :AP=>"Amapa", :BA=>"Bahia", :CE=>"Ceara", :DF=>"Federal District", :ES=>"Espirito Santo", :GO=>"Goias", :MG=>"Minas Gerais", :PB=>"Paraiba", :PE=>"Pernambuco", :PI=>"Piaui", :PR=>"Parana", :RJ=>"Rio de Janeiro", :RN=>"Rio Grande do Norte", :RO=>"Rondonia", :RR=>"Roraima", :RS=>"Rio Grande do Sul", :SE=>"Sergipe", :SP=>"Sao Paulo", :TO=>"Tocantins"}
153
+ ```
154
+
155
+ - Get cities from some states of some countires
156
+
157
+ ```ruby
158
+ Countries.custom_cities({
159
+ "us" => ["ak", "al"],
160
+ "br" => ["ac"]
161
+ })
162
+ ```
163
+ return a array
164
+ ```ruby
165
+ ["Adak", "Akhiok", "Akiachak", "Akiak", "Akutan", "Alakanuk", "Ambler", "Anchor Point", "Anchorage", "Angoon", "Atqasuk", "Barrow", "Bethel", "Big Lake", "Buckland", "Chefornak", "Chevak", "Chicken", "Chugiak", "Coffman Cove", "Cooper Landing", "Copper Center", "Cordova", "Craig", "Delta Junction", "Deltana", "Dillingham", "Douglas", "Dutch Harbor", "Eagle River", "Eielson Air Force Base", "Fairbanks", "Fairbanks North Star Borough", "Fort Greely", "Fort Richardson", "Fort Yukon", "Gakona", "Galena", "Girdwood", "Goodnews Bay", "Haines", "Homer", "Hooper Bay", "Juneau", "Kake", "Kaktovik", "Kalskag", "Kaltag", "Kenai", "Ketchikan", "Kiana", "King Cove", "King Salmon", "Kipnuk", "Klawock", "Kodiak", "Kongiganak", "Kotlik", "Kotzebue", "Koyuk", "Kwethluk", "Levelock", "Manokotak", "May Creek", "Mekoryuk", "Metlakatla", "Mountain Village", "Naknek", "Nazan Village", "Nenana", "New Stuyahok", "Nikiski", "Ninilchik", "Noatak", "Nome", "Nondalton", "Noorvik", "North Pole", "Northway", "Nuiqsut", "Old Kotzebue", "Palmer", "Pedro Bay", "Petersburg", "Pilot Station", "Point Hope", "Point Lay", "Prudhoe Bay", "Russian Mission", "Sand Point", "Scammon Bay", "Selawik", "Seward", "Shungnak", "Sitka", "Skaguay", "Soldotna", "Stebbins", "Sterling", "Sutton", "Talkeetna", "Teller", "Thorne Bay", "Togiak", "Tok", "Toksook Bay", "Tuntutuliak", "Two Rivers", "Unalakleet", "Unalaska", "Valdez", "Wainwright", "Wasilla", "Wrangel", "Abbeville", "Adamsville", "Addison", "Adger", "Alabaster", "Albertville", "Alexander City", "Alexandria", "Aliceville", "Alpine", "Altoona", "America", "Andalusia", "Anniston", "Arab", "Ardmore", "Ariton", "Arley", "Arlington", "Ashford", "Ashland", "Ashville", "Athens", "Atmore", "Attalla", "Auburn", "Autaugaville", "Axis", "Baileyton", "Bankston", "Bay Minette", "Bear Creek", "Berry", "Bessemer", "Birmingham", "Blountsville", "Boaz", "Boligee", "Bremen", "Brent", "Brewton", "Bridgeport", "Brierfield", "Brilliant", "Brookwood", "Brownsboro", "Brundidge", "Bryant", "Butler", "Bynum", "Calera", "Calvert", "Camden", "Carbon Hill", "Carrollton", "Castleberry", "Catherine", "Cecil", "Cedar Bluff", "Centre", "Centreville", "Chancellor", "Chatom", "Chelsea", "Cherokee", "Childersburg", "Chunchula", "Citronelle", "Clanton", "Clayton", "Cleveland", "Clopton", "Coden", "Coffee Springs", "Coker", "Collinsville", "Columbiana", "Cordova", "Cottondale", "Cottonwood", "Courtland", "Crane Hill", "Creola", "Cropwell", "Crossville", "Cullman", "Cusseta", "Dadeville", "Daleville", "Danville", "Daphne", "Dauphin Island", "Daviston", "Dawson", "Deatsville", "Decatur", "Demopolis", "Dixons Mills", "Docena", "Dolomite", "Dora", "Dothan", "Double Springs", "Dozier", "Duncanville", "Dutton", "Eastaboga", "Eclectic", "Eight Mile", "Elba", "Elberta", "Elkmont", "Elmore", "Empire", "Enterprise", "Epes", "Equality", "Estillfork", "Ethelsville", "Eufaula", "Eutaw", "Eva", "Evergreen", "Excel", "Fackler", "Fairfield", "Fairhope", "Falkville", "Fayette", "Fitzpatrick", "Five Points", "Flat Rock", "Flomaton", "Florala", "Florence", "Foley", "Forest Home", "Forkland", "Fort Deposit", "Fort Mitchell", "Fort Payne", "Fort Rucker", "Fosters", "Franklin", "Frisco City", "Fruitdale", "Fulton", "Fultondale", "Fyffe", "Gadsden", "Gainestown", "Gallion", "Gardendale", "Gaylesville", "Geneva", "Georgiana", "Geraldine", "Gilbertown", "Glenwood", "Goodwater", "Gordo", "Gordon", "Goshen", "Grady", "Grand Bay", "Grant", "Graysville", "Greensboro", "Greenville", "Grove Hill", "Grove Oak", "Guin", "Gulf Shores", "Guntersville", "Gurley", "Haleyville", "Hamilton", "Hanceville", "Harpersville", "Hartford", "Hartselle", "Harvest", "Hayden", "Hayneville", "Hazel Green", "Headland", "Heflin", "Helena", "Henagar", "Higdon", "Highland Home", "Holly Pond", "Hollywood", "Hope Hull", "Horton", "Houston", "Huntsville", "Hurtsboro", "Ider", "Irvington", "Jack", "Jackson", "Jacksons Gap", "Jacksonville", "Jasper", "Jemison", "Joppa", "Kellyton", "Kennedy", "Killen", "Kimberly", "Kinston", "Laceys Spring", "Lafayette", "Lanett", "Lapine", "Leeds", "Leesburg", "Leighton", "Leroy", "Letohatchee", "Lexington", "Lillian", "Lincoln", "Linden", "Lineville", "Livingston", "Loachapoka", "Locust Fork", "Logan", "Louisville", "Lowndesboro", "Loxley", "Luverne", "Lynn", "Madison", "Magnolia", "Magnolia Springs", "Maplesville", "Marbury", "Margaret", "Marion", "Marion Junction", "Matthews", "Maylene", "McCalla", "Meridianville", "Midland City", "Midway", "Millbrook", "Millport", "Millry", "Mobile", "Monroeville", "Montevallo", "Montgomery", "Montrose", "Moody", "Morris", "Moulton", "Moundville", "Mount Hope", "Mount Olive", "Mount Vernon", "Mulga", "Munford", "Muscle Shoals", "Natural Bridge", "Nauvoo", "Needham", "New Brockton", "New Hope", "New Market", "Newton", "Newville", "Normal", "Northport", "Notasulga", "Oakman", "Odenville", "Ohatchee", "Oneonta", "Opelika", "Opp", "Orange Beach", "Orrville", "Owens Cross Roads", "Oxford", "Ozark", "Palmerdale", "Pansey", "Parrish", "Pelham", "Pell City", "Perdido", "Peterman", "Phenix City", "Phil Campbell", "Piedmont", "Pike Road", "Pine Hill", "Pinson", "Pisgah", "Pittsview", "Plantersville", "Pleasant Grove", "Prattville", "Quinton", "Ragland", "Rainbow City", "Rainsville", "Ralph", "Ramer", "Ranburne", "Red Bay", "Red Level", "Reform", "Remlap", "Repton", "Riverside", "Roanoke", "Robertsdale", "Rogersville", "Russellville", "Saint Stephens", "Salem", "Samson", "Saraland", "Satsuma", "Scottsboro", "Seale", "Section", "Selma", "Semmes", "Sheffield", "Shelby", "Silas", "Silverhill", "Sipsey", "Slocomb", "Smiths", "Somerville", "Spanish Fort", "Springville", "Spruce Pine", "Stapleton", "Steele", "Sterrett", "Stevenson", "Stockton", "Sulligent", "Sumiton", "Summerdale", "Sweet Water", "Sycamore", "Sylacauga", "Sylvania", "Talladega", "Tallassee", "Tanner", "Theodore", "Thomaston", "Thomasville", "Titus", "Toney", "Town Creek", "Toxey", "Trafford", "Trinity", "Troy", "Trussville", "Tuscaloosa", "Tuscumbia", "Tuskegee", "Union Grove", "Union Springs", "Uriah", "Valhermoso Springs", "Valley", "Valley Head", "Vance", "Vandiver", "Vernon", "Vina", "Vincent", "Vinemont", "Warrior", "Waverly", "Weaver", "Wedowee", "Wellington", "West Blocton", "Wetumpka", "Whatley", "Wilmer", "Wilsonville", "Winfield", "Wing", "Woodstock", "Woodville", "York", "Cruzeiro do Sul", "Foz do Jordao", "Fronteira", "Progresso", "Rio Branco"]
166
+ ```
167
+
168
+ - Get list all cities of a country . Default is ``:us``
169
+
170
+ ```ruby
171
+ Countries.cities_in_country('us')
172
+ ```
173
+
174
+ return a array
175
+ ```ruby
176
+ ["Adak", "Akhiok", "Akiachak", "Akiak", "Akutan", "Alakanuk", "Ambler", "Anchor Point", "Anchorage", "Angoon", "Atqasuk", "Barrow", "Bethel", "Big Lake", "Buckland", "Chefornak", "Chevak", "Chicken", "Chugiak", "Coffman Cove", "Cooper Landing", "Copper Center", "Cordova", "Craig", "Delta Junction", "Deltana",....]
177
+ ```
178
+
112
179
  ## Checkout on Rubygems.org
113
180
  https://rubygems.org/gems/simple-countries
114
181
 
182
+ ## Maintainers
183
+ [x] Libra- (https://github.com/minhquan4080)
184
+
115
185
  ## License
116
186
 
117
187
  The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).
@@ -1,6 +1,6 @@
1
1
  require "simple/countries/version"
2
2
  require 'yaml'
3
- require 'city-state'
3
+ require_relative './cs'
4
4
 
5
5
  module Simple
6
6
  module Countries
@@ -15,7 +15,7 @@ module Simple
15
15
 
16
16
  def self.first
17
17
  @countries = YAML.load_file(File.join(__dir__, 'countries.yml'))
18
- @countries.first
18
+ @countries[1]
19
19
  end
20
20
 
21
21
  def self.last
@@ -1513,7 +1513,7 @@ class Countries
1513
1513
 
1514
1514
  def self.first
1515
1515
  @countries = YAML.load_file(File.join(__dir__, 'countries.yml'))
1516
- @countries.first
1516
+ @countries[1]
1517
1517
  end
1518
1518
 
1519
1519
  def self.last
@@ -1,5 +1,5 @@
1
1
  module Simple
2
2
  module Countries
3
- VERSION = "0.1.2"
3
+ VERSION = "0.1.3"
4
4
  end
5
5
  end
@@ -0,0 +1,5 @@
1
+ require 'city-state'
2
+ require "active_support/all"
3
+
4
+ module CS
5
+ end
@@ -6,11 +6,11 @@ require 'simple/countries/version'
6
6
  Gem::Specification.new do |spec|
7
7
  spec.name = "simple-countries"
8
8
  spec.version = Simple::Countries::VERSION
9
- spec.authors = ["Quan Nguyen"]
9
+ spec.authors = ["Libra-"]
10
10
  spec.email = ["quanmn.libra@gmail.com"]
11
11
 
12
- spec.summary = ""
13
- spec.description = ""
12
+ spec.summary = "Simple Countries"
13
+ spec.description = "This gem is simple get countries, city or states"
14
14
  spec.homepage = ""
15
15
  spec.license = "MIT"
16
16
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: simple-countries
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
- - Quan Nguyen
7
+ - Libra-
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-08-08 00:00:00.000000000 Z
11
+ date: 2017-03-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -66,7 +66,7 @@ dependencies:
66
66
  - - ">="
67
67
  - !ruby/object:Gem::Version
68
68
  version: '0'
69
- description: ''
69
+ description: This gem is simple get countries, city or states
70
70
  email:
71
71
  - quanmn.libra@gmail.com
72
72
  executables: []
@@ -86,6 +86,7 @@ files:
86
86
  - lib/simple/countries.rb
87
87
  - lib/simple/countries.yml
88
88
  - lib/simple/countries/version.rb
89
+ - lib/simple/cs.rb
89
90
  - simple-countries.gemspec
90
91
  homepage: ''
91
92
  licenses:
@@ -107,8 +108,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
107
108
  version: '0'
108
109
  requirements: []
109
110
  rubyforge_project:
110
- rubygems_version: 2.6.6
111
+ rubygems_version: 2.6.8
111
112
  signing_key:
112
113
  specification_version: 4
113
- summary: ''
114
+ summary: Simple Countries
114
115
  test_files: []