A script that generates a list of cities/towns in Japan based on the official 都道府県コード及び市区町村コード version 2023/04/01. It includes English names.
docker run -v "$PWD":/usr/src/app -w /usr/src/app node:8.17-alpine npm audit fix
# https://github.com/nobuf/langlinks-server must be up and running
curl -v http://127.0.0.1:8080
#
git clone https://github.com/nobuf/list-of-cities-in-japan.git
cd list-of-cities-in-japan
docker-compose up --build
ls -l build
id
— 5 digits code that represents the prefectureprefecture_id
— 2 digits version ofid
prefecture_en
— Name in Englishprefecture_ja
— Name in Japanese
id
— 5 digits code that represents the city/town (市区町村)prefecture_id
— 2 digits prefecture IDcity_en
— Name in English. The translation comes from Wikipedia data via langlinks-server. Some names are like "Hakodate, Hokkaido" with its prefecture name while some of them are just "Otaru" without Hokkaido.city_ja
— Name in Japanese.special_district_ja
— Some big cities have special districts (特別区) within the city.
If you have any ideas let @nobuf know by opening an issue. Pull requests are always welcome.
MIT