Skip to content

Commit

Permalink
CLDR-17566 Converting Dev P1 (#4007)
Browse files Browse the repository at this point in the history
  • Loading branch information
chpy04 authored Sep 3, 2024
1 parent 210ceb3 commit 443505c
Show file tree
Hide file tree
Showing 5 changed files with 182 additions and 0 deletions.
7 changes: 7 additions & 0 deletions docs/site/development.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
title: Internal Development
---

# Internal Development

![Unicode copyright](https://www.unicode.org/img/hb_notice.gif)
43 changes: 43 additions & 0 deletions docs/site/development/adding-locales.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
---
title: Adding a new locale to CLDR
---

# Adding a new locale to CLDR

NOTE: this is an internal page for TC developers. Others should see [Core Data for New Locales](https://cldr.unicode.org/index/cldr-spec/core-data-for-new-locales).

### Country Locales

If you are just adding a new country locale (eg we have a locale for the language), you just need to add the new empty locale file, and Update Survey Tool. Otherwise:

### Minimal Structure

Before adding a new locale, you must have the core data: see [Core Data for New Locales](https://cldr.unicode.org/index/cldr-spec/core-data-for-new-locales) for the process.

Here is an example: https://github.com/unicode-org/cldr/pull/59/files

### Add Data in git

- Before starting to add a new locale, make sure you have the minimal core data that cannot be added through the Survey Tool. See above.
- Create the new locale files. If you are adding a single new language locale, for example, language "xx" as spoken in country "YY", you will need two files:
- **common/main/xx.xml** \- The main locale file containing the core data. You can use the template in seed/main/und.xml as a starting point.
- **common/main/xx\_YY.xml** \- An empty country locale containing the identification of xx\_YY as a valid locale. You can use the template in seed/main/und\_XX.xml as a starting point.
- See files are here: https://github.com/unicode-org/cldr/tree/master/seed/main
- Add the plural rules (if available) to **common/supplemental/plurals.xml**
- Add the day period rules (if you have them ) to **common/supplemental/dayPeriods.xml**
- If you are adding a new language
- Add the language subtag to \<variable id\="$language" type\="choice"\> in
- **/common/supplemental/attributeValueValidity.xml**
- add the appropriate default content locale
- to \<defaultContent locales\="..."\> in **common/supplemental/supplementalMetadata.xml**
- The default content locale is usually the locale where the most people speak the language in question.
- If the language is not already in common/supplemental/likelySubtags.xml
- Send the literate pop information to Rick, or file a bug, if the language is not already in the supplemental data.
- Once he has added, run the tool in [LikelySubtags and Default Content](https://cldr.unicode.org/development/updating-codes/likelysubtags-and-default-content) to add the new language and its associated subtags to common/supplemental/likelySubtags.xml
- Also add the English translation for any new languages in **common/main/en.xml**
- If requested, add to vendor targets (Locale.txt), and to Cldr where resources are committed.
- Run the tests (will be done automatically when a PR is created)
- Commit your work to a branch and create a Pull Request.
- The new locale will be included in Smoketest when the PR is merged, and will be in production once a push to production occurs.

![Unicode copyright](https://www.unicode.org/img/hb_notice.gif)
31 changes: 31 additions & 0 deletions docs/site/development/cldr-big-red-switch.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
---
title: CLDR: Big Red Switch
---

# CLDR: Big Red Switch

## What to do before we release for CLDR version X (current version X \= 28\):

*All: remember to make sure that the* ***target: X*** *is set on all the X bugs, otherwise the Release Changes link won't pick them up.*

*Items marked \* are for the "Little Red Switch": dot\-dot releases (supplemental data, ids, timezones, small spec fixes). Items marked \*\* are only done for a LRS if there was a DTD change.*

### Trial New Version (Let us know if you need write access!)

(For editors: [List View of BRS](https://cldr.unicode.org/development/cldr-big-red-switch/list-view-of-brs), [Spreadsheet View](https://docs.google.com/spreadsheets/d/1dIOLxKX2gW7BRDVdMBH9qr1GdxpPj8Bc1Pe-02p_92k/edit#gid=0))

## Contributor Message

For each release, we add names to the Unicode CLDR Acknowledgments page:

http://cldr.unicode.org/index/acknowledgments.

However, names are not automatically entered there, since some people may not wish to have their names listed. If your name is not there and you would like it to be, please send me your name as it should appear on that page. Your name should be in Latin characters, optionally with names in one or more other scripts in parentheses, such as "Vladimir Weinstein (Владимир Вајнштајн)"

**\-\-\-\- how to send this message: currently a crude process \-\-\-\-**

1. get list of those who contributed through Survey tool (Login as TC, under 'Manage Users', click 'Email Address of Users Who Participated' (shows all users, not just your org)
2. e\-mail that list **on BCC:** the above message with a subject line of "\[CLDR X.Y Contributor Message]", and a request to please keep the subject line intact.
3. Then, the subject line can be used to filter/locate the contributor requests.

![Unicode copyright](https://www.unicode.org/img/hb_notice.gif)
67 changes: 67 additions & 0 deletions docs/site/development/cldr-big-red-switch/generating-charts.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
---
title: Generating Charts
---

# Generating Charts

## Generate

The input for this is the cldr\-staging/production file, and the output is in github cldr\-staging. **(If for the development version, the input is main or the maint branch, but we should change that.)**

1. Make sure the settings and VM arguments are right for where you are in the release:
1. **Start, Mid\-release, Prefinal release,** or **Final release** (see below)
2. Run GenerateAllCharts. The results for each will be in ... cldr\-staging/docs/charts/by\_type/names.currency.html and so on.
3. Spot\-check for sanity.
1. Start from the main page (eg cldr\-staging/docs/charts/index.html), and click on each of those links.
2. On each of the subpages, take the first chart on each page, recursively.
3. Use the "Index" link to go back up (not the back button), and make sure it goes to the right version of the page.
4. Check into github on cldr\-staging

## Start Release

1. Make sure the version  (eg **99**) is right in ToolConstants
1. Make sure the *last* number (eg **99\.0**) is in CLDR\_VERSIONS
2. Set DEFAULT\_CHART\_VERSION \= "99";
2. Add an new folder with that number, such as cldr\-staging/docs/charts/**99**
3. Create the archive ([Creating the Archive](https://cldr.unicode.org/development/creating-the-archive)) with at least the last release (if you don't have it already)
4. **Use the same VM arguments as Mid\-Release**

## Mid\-release

1. Use the VM arguements
1. \-DCHART\_VERSION\=**99**
2. \-DCHART\_STATUS\=**beta** // \=*default*, uses trunk, calls it β

## Prefinal Release

1. VM Arguments
1. \-DCHART\_VERSION\=**99**
2. \-DCHART\_STATUS\=**trunk** (uses trunk, no β. Used at the end of the release, but before the final data is in cldr\-archive)
2. In the printout from delta\_summary.txt, there is a listing of the sizes at the top
1. Something like the following:
1. \# dir file added deleted changed total
1. TOTAL 30,276 3,601 10,909 2,153,094
2. Add those new figures to the release page

## Final Release

1. Make sure the settings are:
1. \-DCHART\_VERSION\=**99**
2. \-DCHART\_STATUS\=**release** (only uses the cldr\-archive, no β)
2. Change the page <http://cldr.unicode.org/index/charts> to add the new release
3. Check the redirection links on [test\-chart\-links](https://cldr.unicode.org/development/cldr-big-red-switch/test-chart-links).
4. On index.html; open it, and fix the version (eg to 25β \=\> 25\)

## Modifying the chart programs

The chart programs have grown over time, and need some cleanup. For example, the supplemental charts duplicate code that is now in SupplementalDataInfo. 

### ShowLanguages.

The messages that they use are in a file util/data/chart\_messages.html. The right cell contains the key, which is extracted by lines like:

&emsp;PrintWriter pw \= new PrintWriter(new FormattedFileWriter(index, "Zone \\u2192 Tzid", null));

The key will be zone\_tzid, in this case.

![Unicode copyright](https://www.unicode.org/img/hb_notice.gif)
34 changes: 34 additions & 0 deletions docs/site/development/cldr-development-site/running-cldr-tools.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
---
title: Running CLDR Tools
---

# Running CLDR Tools

You will need to include some options to run various programs. Here are some samples, but the directories may vary depending on your configuration.

**Standard Gorp**

\-Dfile.encoding\=UTF\-8

\-Xmx3000m

\-DCLDR\_DIR\=${workspace\_loc}/cldr

\-DOTHER\_WORKSPACE\=${workspace\_loc}/"../Google Drive/workspace/"

\-DCLDR\_GEN\_DIR\=${workspace\_loc}/"../Google Drive/workspace/Generated/cldr/"

\-Dregistry\=language\-subtag\-registry

\-DSHOW\_FILES

The xmx is to increase memory so that you don't blow up. If you only do a few dozen locales, you don't need to set it that high.

**Optional**

\-f regex // to only check locales matching the regex, like ".\*" or "en\|fr\|de" ...

\-DSHOW\_FILES // shows files being opened and created


![Unicode copyright](https://www.unicode.org/img/hb_notice.gif)

0 comments on commit 443505c

Please sign in to comment.