Asnad Atta
Asnad Atta

Reputation: 4003

How to add new country?

I am using countries and country_select gems. There are some countries missing in the gems, or states of a country is it possible can we add new countries or states with custom data and use in our rails project.? What I need to do that?

Upvotes: 1

Views: 116

Answers (2)

Shalev Shalit
Shalev Shalit

Reputation: 1963

Change the yaml file: https://github.com/hexorx/countries/blob/master/lib/cache/translations.yaml

If you have made changes to YAML run rake clean_yaml prior to committing to ensure your YAML is formatted properly.

Upvotes: 1

zwippie
zwippie

Reputation: 15515

Clone the gem repositories, make your changes and in your projects Gemfile refer to your own repositories for those gems. If you think your changes are useful for the community: make a pull request for the original project.

Upvotes: 5

Related Questions