Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CONTRIBUTING address review comments #1384

Merged
merged 1 commit into from
Oct 16, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 9 additions & 9 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,14 @@ In order to keep Datafaker slim and focused the project generally attempts to av

## Languages and countries

Localization files are located in folder `src/main/resources`
1. Country-specific values are stored in files `_COUNTRY.yml` (e.g. `_AL.yml` for Albania)
* these are value that are the same in all languages in this country (e.g. phone country code, passport number pattern etc.)
2. Language-specific values are stored in files `language.yml` (e.g. `it.yml` for Italian)
* these are cities, streets, names etc. in that languages.
3. In files `language-COUNTRY.yml`, we store values specific for this language and country
Localization files are located in folder `src/main/resources`.
1. Country-specific values are stored in files `_COUNTRY.yml` (e.g. `_AL.yml` for Albania).
* these are value that are the same in all languages in this country (e.g. phone country code, passport number pattern, etc.).
2. Language-specific values are stored in files `language.yml` (e.g. `it.yml` for Italian).
* these are cities, streets, names etc. in that language.
3. In files `language-COUNTRY.yml`, we store values specific for this language and country.
* e.g. `ru-MD.yml` contains Moldovan city names in Russian language (that is widely used in Moldova).

After adding a new country or language, don't forget to update
* constant `net.datafaker.providers.base.Locality.LOCALES`
* tests in `LocalityTest.java`
After adding a new country or language, don't forget to update:
* constant `net.datafaker.providers.base.Locality.LOCALES`.
* tests in `LocalityTest.java`.