Skip to content

Commit

Permalink
introduce new format for languages (update from @herrniemand) fix mle…
Browse files Browse the repository at this point in the history
…doze#78

fix native names
  • Loading branch information
mledoze committed Sep 11, 2014
1 parent 35d6f3e commit cf6717b
Show file tree
Hide file tree
Showing 6 changed files with 4,547 additions and 3,879 deletions.
91 changes: 48 additions & 43 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@
## Countries data
This repository contains lists of world countries in JSON, CSV and XML. Each line contains the country:

- name
- common - common name
- official - official name
- native
- common - native common name
- official - native official name
- `name`
- `common` - common name in english
- `official` - official name in english
- `native`
- `common` - common name in the native language
- `official` - official name in the native language
- country code top-level domain (`tld`)
- code ISO 3166-1 alpha-2 (`cca2`)
- code ISO 3166-1 numeric (`ccn3`)
Expand All @@ -19,8 +19,10 @@ This repository contains lists of world countries in JSON, CSV and XML. Each lin
- relevance
- region
- subregion
- language(s) in English (`language`)
- ISO 639-1 language code(s) (`languageCodes`)
- native language (`nativeLanguage`) ISO 639-3 code of language used for the native names
- list of official languages (`languages`)
- key: three-letter ISO 639-3 language code
- value: name of the language in english
- name translations (`translations`)
- latitude and longitude (`latlng`)
- name of residents (`demonym`)
Expand All @@ -39,8 +41,8 @@ GeoJSON outlines and flags in SVG format.
"common": "Austria",
"official": "Republic of Austria",
"native": {
"common": "\u00d6sterreich",
"official": "Republik \u00d6sterreich"
"common": "Österreich",
"official": "Republik Österreich"
}
},
"tld": [".at"],
Expand All @@ -50,22 +52,24 @@ GeoJSON outlines and flags in SVG format.
"currency": ["EUR"],
"callingCode": ["43"],
"capital": "Vienna",
"altSpellings": ["AT", "\u00d6sterreich", "Osterreich", "Oesterreich"],
"altSpellings": ["AT", "Österreich", "Osterreich", "Oesterreich"],
"relevance": "0",
"region": "Europe",
"subregion": "Western Europe",
"language": ["German"],
"languageCodes": ["de"],
"nativeLanguage": "deu",
"languages": {
"deu": "German"
},
"translations": {
"cy": "Awstria",
"fr": "Autriche",
"it": "Austria",
"nl": "Oostenrijk",
"ja": "\u30aa\u30fc\u30b9\u30c8\u30ea\u30a2",
"es": "Austria",
"ru": "\u0410\u0432\u0441\u0442\u0440\u0438\u044f",
"de": "\u00d6sterreich",
"hr": "Austrija"
"cym": "Awstria",
"deu": "Österreich",
"fra": "Autriche",
"hrv": "Austrija",
"ita": "Austria",
"jpn": "オーストリア",
"nld": "Oostenrijk",
"rus": "Австрия",
"spa": "Austria"
},
"latlng": [47.33333333, 13.33333333],
"demonym": "Austrian",
Expand All @@ -88,21 +92,23 @@ GeoJSON outlines and flags in SVG format.
"currency": ["NGN"],
"callingCode": ["234"],
"capital": "Abuja",
"altSpellings": ["NG", "Nijeriya", "Na\u00edj\u00edr\u00ed\u00e0", "Federal Republic of Nigeria"],
"altSpellings": ["NG", "Nijeriya", "Naíjíríà", "Federal Republic of Nigeria"],
"relevance": "1.5",
"region": "Africa",
"subregion": "Western Africa",
"language": ["English"],
"languageCodes": ["en"],
"nativeLanguage": "eng",
"languages": {
"eng": "English"
},
"translations": {
"fr": "Nig\u00e9ria",
"it": "Nigeria",
"nl": "Nigeria",
"ja": "\u30ca\u30a4\u30b8\u30a7\u30ea\u30a2",
"es": "Nigeria",
"ru": "\u041d\u0438\u0433\u0435\u0440\u0438\u044f",
"de": "Nigeria",
"hr": "Nigerija"
"deu": "Nigeria",
"fra": "Nigéria",
"hrv": "Nigerija",
"ita": "Nigeria",
"jpn": "ナイジェリア",
"nld": "Nigeria",
"rus": "Нигерия",
"spa": "Nigeria"
},
"latlng": [10, 8],
"demonym": "Nigerian",
Expand All @@ -116,23 +122,23 @@ See an example for [Germany](https://github.com/mledoze/countries/blob/bb61a1cdd

#####CSV
```csv
"name";"tld";"cca2";"ccn3";"cca3";"currency";"callingCode";"capital";"altSpellings";"relevance";"region";"subregion";"language";"languageCodes";"translations";"latlng";"demonym";"borders";"area"
"name";"tld";"cca2";"ccn3";"cca3";"currency";"callingCode";"capital";"altSpellings";"relevance";"region";"subregion";"nativeLanguage";"languages";"translations";"latlng";"demonym";"borders";"area"
"Afghanistan,افغانستان";".af";"AF";"004";"AFG";"AFN";"93";"Kabul";"AF,Afġānistān";"0";"Asia";"Southern Asia";"Pashto,Dari";"ps,uz,tk";"アフガニスタン,Affganistan,Afghanistan,Afghanistan,Afganistán,Afganistan,Афганистан,Afghanistan,Afghanistan";"33,65";"Afghan";"IRN,PAK,TKM,UZB,TJK,CHN";"652230"
"Åland Islands,Åland";".ax";"AX";"248";"ALA";"EUR";"358";"Mariehamn";"AX,Aaland,Aland,Ahvenanmaa";"0";"Europe";"Northern Europe";"Swedish";"sv";"オーランド諸島,Ålandeilanden,Isole Aland,Alandia,Ålandski otoci,Аландские острова,Åland,Åland";"60.116667,19.9";"Ålandish";"";"-1"
"Albania,Shqipëria";".al";"AL";"008";"ALB";"ALL";"355";"Tirana";"AL,Shqipëri,Shqipëria,Shqipnia";"0";"Europe";"Southern Europe";"Albanian";"sq";"アルバニア,Albania,Albanië,Albania,Albania,Albanija,Албания,Albanie,Albanien";"41,20";"Albanian";"MNE,GRC,MKD,KOS";"28748"
"Algeria,الجزائر";".dz,الجزائر.";"DZ";"012";"DZA";"DZD";"213";"Algiers";"DZ,Dzayer,Algérie";"0";"Africa";"Northern Africa";"Arabic";"ar";"アルジェリア,Algeria,Algerije,Algeria,Argelia,Alžir,Алжир,Algérie,Algerien";"28,3";"Algerian";"TUN,LBY,NER,ESH,MRT,MLI,MAR";"2381741"
"Afghanistan,Islamic Republic of Afghanistan,افغانستان,د افغانستان اسلامي جمهوریت";".af";"AF";"004";"AFG";"AFN";"93";"Kabul";"AF,Afġānistān";"0";"Asia";"Southern Asia";"pus";"Dari,Pashto,Turkmen";"Affganistan,Afghanistan,Afghanistan,Afganistan,Afghanistan,アフガニスタン,Afghanistan,Афганистан,Afganistán";"33,65";"Afghan";"IRN,PAK,TKM,UZB,TJK,CHN";"652230"
"Åland Islands,Åland Islands,Åland,Landskapet Åland";".ax";"AX";"248";"ALA";"EUR";"358";"Mariehamn";"AX,Aaland,Aland,Ahvenanmaa";"0";"Europe";"Northern Europe";"swe";"Swedish";"Åland,Åland,Ålandski otoci,Isole Aland,オーランド諸島,Ålandeilanden,Аландские острова,Alandia";"60.116667,19.9";"Ålandish";"";"-1"
"Albania,Republic of Albania,Shqipëria,Republika e Shqipërisë";".al";"AL";"008";"ALB";"ALL";"355";"Tirana";"AL,Shqipëri,Shqipëria,Shqipnia";"0";"Europe";"Southern Europe";"sqi";"Albanian";"Albania,Albanien,Albanie,Albanija,Albania,アルバニア,Albanië,Албания,Albania";"41,20";"Albanian";"MNE,GRC,MKD,KOS";"28748"
"Algeria,People's Democratic Republic of Algeria,الجزائر,الجمهورية الديمقراطية الشعبية الجزائرية";".dz,الجزائر.";"DZ";"012";"DZA";"DZD";"213";"Algiers";"DZ,Dzayer,Algérie";"0";"Africa";"Northern Africa";"ara";"Arabic";"Algeria,Algerien,Algérie,Alžir,Algeria,アルジェリア,Algerije,Алжир,Argelia";"28,3";"Algerian";"TUN,LBY,NER,ESH,MRT,MLI,MAR";"2381741"
```

#####XML
```xml
<?xml version="1.0" encoding="UTF-8"?>
<countries>
<country name="Afghanistan,افغانستان" tld=".af" cca2="AF" ccn3="004" cca3="AFG" currency="AFN" callingCode="93" capital="Kabul" altSpellings="AF,Afġānistān" relevance="0" region="Asia" subregion="Southern Asia" language="Pashto,Dari" languageCodes="ps,uz,tk" translations="アフガニスタン,Affganistan,Afghanistan,Afghanistan,Afganistán,Afganistan,Афганистан,Afghanistan,Afghanistan" latlng="33,65" demonym="Afghan" borders="IRN,PAK,TKM,UZB,TJK,CHN" area="652230"/>
<country name="Åland Islands,Åland" tld=".ax" cca2="AX" ccn3="248" cca3="ALA" currency="EUR" callingCode="358" capital="Mariehamn" altSpellings="AX,Aaland,Aland,Ahvenanmaa" relevance="0" region="Europe" subregion="Northern Europe" language="Swedish" languageCodes="sv" translations="オーランド諸島,Ålandeilanden,Isole Aland,Alandia,Ålandski otoci,Аландские острова,Åland,Åland" latlng="60.116667,19.9" demonym="Ålandish" borders="" area="-1"/>
<country name="Albania,Shqipëria" tld=".al" cca2="AL" ccn3="008" cca3="ALB" currency="ALL" callingCode="355" capital="Tirana" altSpellings="AL,Shqipëri,Shqipëria,Shqipnia" relevance="0" region="Europe" subregion="Southern Europe" language="Albanian" languageCodes="sq" translations="アルバニア,Albania,Albanië,Albania,Albania,Albanija,Албания,Albanie,Albanien" latlng="41,20" demonym="Albanian" borders="MNE,GRC,MKD,KOS" area="28748"/>
<country name="Algeria,الجزائر" tld=".dz,الجزائر." cca2="DZ" ccn3="012" cca3="DZA" currency="DZD" callingCode="213" capital="Algiers" altSpellings="DZ,Dzayer,Algérie" relevance="0" region="Africa" subregion="Northern Africa" language="Arabic" languageCodes="ar" translations="アルジェリア,Algeria,Algerije,Algeria,Argelia,Alžir,Алжир,Algérie,Algerien" latlng="28,3" demonym="Algerian" borders="TUN,LBY,NER,ESH,MRT,MLI,MAR" area="2381741"/>
<country name="Afghanistan,Islamic Republic of Afghanistan,افغانستان,د افغانستان اسلامي جمهوریت" tld=".af" cca2="AF" ccn3="004" cca3="AFG" currency="AFN" callingCode="93" capital="Kabul" altSpellings="AF,Afġānistān" relevance="0" region="Asia" subregion="Southern Asia" nativeLanguage="pus" languages="Dari,Pashto,Turkmen" translations="Affganistan,Afghanistan,Afghanistan,Afganistan,Afghanistan,アフガニスタン,Afghanistan,Афганистан,Afganistán" latlng="33,65" demonym="Afghan" borders="IRN,PAK,TKM,UZB,TJK,CHN" area="652230"/>
<country name="Åland Islands,Åland Islands,Åland,Landskapet Åland" tld=".ax" cca2="AX" ccn3="248" cca3="ALA" currency="EUR" callingCode="358" capital="Mariehamn" altSpellings="AX,Aaland,Aland,Ahvenanmaa" relevance="0" region="Europe" subregion="Northern Europe" nativeLanguage="swe" languages="Swedish" translations="Åland,Åland,Ålandski otoci,Isole Aland,オーランド諸島,Ålandeilanden,Аландские острова,Alandia" latlng="60.116667,19.9" demonym="Ålandish" borders="" area="-1"/>
<country name="Albania,Republic of Albania,Shqipëria,Republika e Shqipërisë" tld=".al" cca2="AL" ccn3="008" cca3="ALB" currency="ALL" callingCode="355" capital="Tirana" altSpellings="AL,Shqipëri,Shqipëria,Shqipnia" relevance="0" region="Europe" subregion="Southern Europe" nativeLanguage="sqi" languages="Albanian" translations="Albania,Albanien,Albanie,Albanija,Albania,アルバニア,Albanië,Албания,Albania" latlng="41,20" demonym="Albanian" borders="MNE,GRC,MKD,KOS" area="28748"/>
<country name="Algeria,People's Democratic Republic of Algeria,الجزائر,الجمهورية الديمقراطية الشعبية الجزائرية" tld=".dz,الجزائر." cca2="DZ" ccn3="012" cca3="DZA" currency="DZD" callingCode="213" capital="Algiers" altSpellings="DZ,Dzayer,Algérie" relevance="0" region="Africa" subregion="Northern Africa" nativeLanguage="ara" languages="Arabic" translations="Algeria,Algerien,Algérie,Alžir,Algeria,アルジェリア,Algerije,Алжир,Argelia" latlng="28,3" demonym="Algerian" borders="TUN,LBY,NER,ESH,MRT,MLI,MAR" area="2381741"/>
<countries>
```
Expand All @@ -154,7 +160,6 @@ Projects using this dataset:
Please refer to [CONTRIBUTING](https://github.com/mledoze/countries/blob/master/CONTRIBUTING.md).

## To do
- add the official name of the country in english and in its native language
- add the type of the country (country, sovereign state, public body, territory, etc.)
- add missing translations

Expand Down
Loading

0 comments on commit cf6717b

Please sign in to comment.