Skip to content
Merged
Show file tree
Hide file tree
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
33 changes: 24 additions & 9 deletions docs/devsetup/java/maven/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,11 @@ The command line invocation is still, of course, the standard of truth for the b
## Installation

Install Maven from your OS package manager.
The minimum version is 3.2.5 as of ICU 74,
although this may change.
See the `<ICU>/icu4j/pom.xml` root POM file's maven-enforcer-plugin
The minimum version is 3.9.0 as of ICU 79, although this may change.
See the `<ICU>/pom.xml` root POM file's `maven-enforcer-plugin`
for the current minimum version.
The Maven page lists [system requirements](https://maven.apache.org/download.cgi),
which includes a minimum of JDK 8 as of ICU 74.
which includes a minimum of JDK 11 as of ICU 78.

## Maven multi-module projects

Expand All @@ -48,7 +47,7 @@ Commonly-found instructions to use Maven at the command line
are usually designed for simple "single-module" Maven projects.
In such cases, the command names correspond intuitively to their function:
`mvn test` for running unit tests, `mvn package` for creating jar files, etc.
However, multi-module projects have the tradeoff between time and complexity:
However, multi-module projects have the trade-off between time and complexity:
running `mvn test` at the root recompiles all the sources
even if a module's sources are all unchanged,
which takes longer than it otherwise could.
Expand All @@ -65,8 +64,7 @@ The instructions in this page for command line usage will choose,
from the 2 alternatives above,
the option that consistently uses `mvn install` for all Maven tasks.
Note that this choice should not affect IDEs with well working native Maven support like IntelliJ and Eclipse.
See the "IDE Setup" section for more details on how IDEs handle Maven projects differently than
the standard command line style usage of Maven.
See the "IDE Setup" section for more details on how IDEs handle Maven projects differently than the standard command line style usage of Maven.

## IDE Setup

Expand Down Expand Up @@ -96,7 +94,9 @@ To import into IntelliJ:

1. In IntelliJ, open a new project.
a. Recent versions of IntelliJ provide a dialog box on startup to select a project. Click the "Open" button.)
2. Select the root `pom.xml` in ICU4J (ex: `<ICU>/icu4j/pom.xml`)
2. Select the root `pom.xml` in ICU4J. Can be `<ICU>/icu4j/pom.xml` or `<ICU>/pom.xml`.
If you don't work on any module under `<ICU>/tools` then opening the `icu4j/` project
is less "noisy."
3. That's it. Note: IntelliJ will take a few minutes to do a one-time indexing of the new source code.

Navigating the source code files between main code and test code, and running tests individually or for an entire module,
Expand All @@ -106,7 +106,22 @@ work as they do normally in IntelliJ.

[Eclipse's Maven plugin](https://eclipse.dev/m2e/)
works reasonably well and can support the import of a multi-module Maven project.
These instructions have not yet verified Eclipse's handling of the import of the ICU4J using a Maven build.

1. It is highly recommended (but optional) to do the ICU work in a separate workspace. \
You can also import to a working-set. Whatever you prefer. \
A workspace allows you to configure the Eclipse options for ICU at workspace level,
not at module level. It also separates the (many) ICU modules from the other work
you do. The downside is that whenever you open Eclipse, you will have to select
the workspace to work on.
See the official Eclipse [Workspaces](https://www.ibm.com/docs/en/baw/23.0.x?topic=modules-workspaces) page for more.
1. From "Settings" -- "Startup and Shutdown" -- "Workspaces" check the
"Prompt for workspace on startup" option.
2. Restart Eclipse, and when prompted type a workspace name
(for example `/Users/john/workspace_icu`).
2. Start Eclipse (choosing the workspace you prefer)
3. Import ICU Maven projects. "File" -- "Import" -- "Maven" -- "Existing Maven projects"
4. Navigate to the `<ICU>` or `<ICU>/icu4j`. Both work.
The root is more "noisy", so if you don't plan to work on anything under `<ICU>/tools` you can import the `icu4j/` submodule instead.

### VS Code

Expand Down
18 changes: 14 additions & 4 deletions docs/processes/release/tasks/versions.md
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,16 @@ Edit icuver.txt directly.

### ICU4J

#### Since ICU 79

> :point_right: **Note**: The maven commands _must_ be executed from the
root of the ICU project, not from `<ICU>/icu4j`. This is a slight change from ICU versions 74-78.

```sh
cd $ICU_DIR
mvn versions:set -DnewVersion=79.1 -DgenerateBackupPoms=false
```

#### Since ICU 74

Changing the version for Java starting with ICU 74 requires a few steps:
Expand Down Expand Up @@ -146,7 +156,7 @@ Changing the version for Java starting with ICU 74 requires a few steps:
UNICODE_6_2 = getInstance(6, 2, 0, 0);
UNICODE_6_3 = getInstance(6, 3, 0, 0);
UNICODE_7_0 = getInstance(7, 0, 0, 0);
<b>
<b style="color:red">
ICU_VERSION = getInstance(74, 1, 0, 0);
ICU_DATA_VERSION = ICU_VERSION;</b>
UNICODE_VERSION = UNICODE_7_0;
Expand All @@ -167,7 +177,7 @@ Changing the version for Java starting with ICU 74 requires a few steps:
* @deprecated This API is ICU internal only.
*/
@Deprecated
public static final String <b>ICU_DATA_VERSION_PATH = "74b";</b>
public static final String <b style="color:red">ICU_DATA_VERSION_PATH = "74b";</b>
</pre>

2. [icu4j/main/core/src/test/java/com/ibm/icu/dev/test/util/DebugUtilitiesData.java](https://github.com/unicode-org/icu/blob/main/icu4j/main/core/src/test/java/com/ibm/icu/dev/test/util/DebugUtilitiesData.java)
Expand Down Expand Up @@ -195,15 +205,15 @@ The command requires a version number string that follows the typical Java / Mav
With the proper new version number, run the following Maven command to update the version numbers
throughout all of the ICU4J `pom.xml` build files.

```
```sh
mvn versions:set -DnewVersion=74.1 -DgenerateBackupPoms=false
```

4. Immediately after creating the final release of a major ICU version, update the value that represents just the major version number of the semantic version. To do this, update the value of the ICU `icu.major.version` property in the root Maven pom.xml file at `icu4j/pom.xml`.

This can be done by running the following command:

```
```sh
mvn versions:set-property -DnewVersion=74 -Dproperty=icu.major.version -DgenerateBackupPoms=false
```

Expand Down
2 changes: 1 addition & 1 deletion docs/userguide/icu/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ open components, and look forward to your questions, comments and suggestions.

Download ICU in one of the following ways:

1. From the download page, <https://icu.unicode.org/download>, for
1. From the download page, <https://unicode-org.github.io/icu/download>, for
packaged stable releases of ICU.

2. From the source code repository, <https://github.com/unicode-org/icu/releases/>,
Expand Down
4 changes: 2 additions & 2 deletions docs/userguide/icu/release.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@ License & terms of use: http://www.unicode.org/copyright.html

## What Is New In The Current Release?

See the [ICU download page](https://icu.unicode.org/download/) to find the subpage for the current release.
See the [ICU download page](https://unicode-org.github.io/icu/download/) to find the subpage for the current release.

The subpage for the current release will contain information on changes since the last release, bug fixes, known issues, changes to supported platforms and build environments, and migration issues for existing applications migrating from previous ICU releases. The page will also include an API Change Report, both for ICU4C and ICU4J, for a complete list of APIs added, removed, or changed in this release.

Changes in previous releases can also be found the main [ICU download page](https://icu.unicode.org/download) in its version-specific subpages.
Changes in previous releases can also be found the main [ICU download page](https://unicode-org.github.io/icu/download) in its version-specific subpages.

## License Information

Expand Down
4 changes: 2 additions & 2 deletions docs/userguide/icu4c/faq.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ formatting, text boundary detection, character set conversion and so on.

#### Where can I get ICU?

You can get ICU4C and ICU4J from <https://icu.unicode.org/download>
You can get ICU4C and ICU4J from <https://unicode-org.github.io/icu/download>

**Why don't you build binaries for my platform?**

Expand Down Expand Up @@ -276,7 +276,7 @@ section in the [ICU Design](../design.md) chapter.
ICU versions 65 supports Unicode version 12.

The Unicode versions for older versions of ICU are listed on the ICU download
page, <https://icu.unicode.org/download>
page, <https://unicode-org.github.io/icu/download>

#### Does ICU support UTF-16 surrogates and Unicode supplementary characters?

Expand Down
25 changes: 12 additions & 13 deletions docs/userguide/icu4c/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,35 +45,34 @@ The ICU homepage also links to related information about writing internationaliz

**Here are some useful links regarding ICU and internationalization in general.**


| ICU, ICU4C & ICU4J Homepage | <https://icu.unicode.org/> |
| ICU FAQ - Frequently Asked Questions about ICU | <https://unicode-org.github.io/icu/userguide/icu4c/faq> |
| ICU4J FAQ - Frequently Asked Questions about ICU4J | <https://unicode-org.github.io/icu/userguide/icu4j/faq> |
| ICU User's Guide | <https://unicode-org.github.io/icu/> |
| How To Use ICU | <https://unicode-org.github.io/icu/userguide/icu/howtouseicu> |
| Download ICU Releases | <https://icu.unicode.org/download> |
| ICU4C API Documentation Online | <https://unicode-org.github.io/icu-docs/apidoc/released/icu4c/> |
| Online ICU Demos | <https://icu4c-demos.unicode.org/icu-bin/icudemos> |
| Contacts and Bug Reports/Feature Requests | <https://icu.unicode.org/contacts> |
| ICU, ICU4C & ICU4J Homepage | <https://icu.unicode.org/> |
| ICU FAQ - Frequently Asked Questions about ICU | <https://unicode-org.github.io/icu/userguide/icu4c/faq> |
| ICU4J FAQ - Frequently Asked Questions about ICU4J | <https://unicode-org.github.io/icu/userguide/icu4j/faq> |
| ICU User's Guide | <https://unicode-org.github.io/icu/> |
| How To Use ICU | <https://unicode-org.github.io/icu/userguide/icu/howtouseicu> |
| Download ICU Releases | <https://unicode-org.github.io/icu/download> |
| ICU4C API Documentation Online | <https://unicode-org.github.io/icu-docs/apidoc/released/icu4c/> |
| Online ICU Demos | <https://icu4c-demos.unicode.org/icu-bin/icudemos> |
| Contacts and Bug Reports/Feature Requests | <https://icu.unicode.org/contacts> |

**Important:** Please make sure you understand the [Copyright and License Information](https://github.com/unicode-org/icu/blob/main/LICENSE).

## What Is New In The Current Release?

See the [ICU download page](https://icu.unicode.org/download/) to find the subpage for the current release, including any other changes, bug fixes, known issues, changes to supported platforms and build environments, and migration issues for existing applications migrating from previous ICU releases.
See the [ICU download page](https://unicode-org.github.io/icu/download/) to find the subpage for the current release, including any other changes, bug fixes, known issues, changes to supported platforms and build environments, and migration issues for existing applications migrating from previous ICU releases.

The subpage for the current release will also include an API Change Report, both for ICU4C and ICU4J, for a complete list of APIs added, removed, or changed in this release.

The list of API changes since the previous ICU4C release is available [here](https://htmlpreview.github.io/?https://raw.githubusercontent.com/unicode-org/icu/main/icu4c/APIChangeReport.html).

Changes in previous releases can also be found on the main [ICU download page](https://icu.unicode.org/download) in its version-specific subpages.
Changes in previous releases can also be found on the main [ICU download page](https://unicode-org.github.io/icu/download) in its version-specific subpages.

## How To Download the Source Code

There are two ways to download ICU releases:

* **Official Release Snapshot:**
If you want to use ICU (as opposed to developing it), you should download an official packaged version of the ICU source code. These versions are tested more thoroughly than day-to-day development builds of the system, and they are packaged in zip and tar files for convenient download. These packaged files can be found at [https://icu.unicode.org/download](https://icu.unicode.org/download).
If you want to use ICU (as opposed to developing it), you should download an official packaged version of the ICU source code. These versions are tested more thoroughly than day-to-day development builds of the system, and they are packaged in zip and tar files for convenient download. These packaged files can be found at [https://unicode-org.github.io/icu/download](https://unicode-org.github.io/icu/download).
The packaged snapshots are named `icu-nnnn.zip` or `icu-nnnn.tgz`, where `nnnn` is the version number. The .zip file is used for Windows platforms, while the .tgz file is preferred on most other platforms.
Please unzip this file.
> :point_right: **Note**: There may be additional commits on the `maint-*` branch for a particular version that are not included in the prepackaged download files.
Expand Down
54 changes: 45 additions & 9 deletions docs/userguide/icu4j/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ ICU4J is an add-on to the regular JRE that provides:

## Platform Dependencies

Check the [Downloading ICU](https://icu.unicode.org/download) page to look up the minimum supported version of Java
Check the [Downloading ICU](https://unicode-org.github.io/icu/download/) page to look up the minimum supported version of Java
for your version of ICU.

## How to Download ICU4J
Expand All @@ -64,7 +64,7 @@ There are a few different ways to download the ICU4J releases.

* **Official Release:**
If you want to use ICU4J (as opposed to developing it), your best bet is to download an official, packaged version of the ICU4J library files. These versions are tested more thoroughly than day-to-day development builds, and they are packaged in jar files for convenient download.
* [ICU Download page](https://icu.unicode.org/download)
* [ICU Download page](https://unicode-org.github.io/icu/download/)
* Maven repository:

```
Expand All @@ -90,8 +90,16 @@ There are a few different ways to download the ICU4J releases.
* **GitHub Source Repository:**
If you are interested in developing features, patches, or bug fixes for ICU4J, you should probably be working with the latest version of the ICU4J source code. You will need to clone and checkout the code from our GitHub repository to ensure that you have the most recent version of all of the files. There are several ways to do this. Please follow the directions that are contained on the [Source Code Setup page](../../devsetup/source/) for details.

For more details on how to download ICU4J directly from the web site, please see the ICU download page at [https://icu.unicode.org/download](https://icu.unicode.org/download)
For more details on how to download ICU4J directly from the web site, please see the ICU download page at
<https://unicode-org.github.io/icu/download>

## The Structure and Contents of ICU4J - ICU 79 and later

The structure is identical to ICU 74-78, but there is also a Maven project in the ICU root, and in
intermediate folders like `<ICU>/icu4j/main` and `<ICU>/icu4j/tools`.

These projects only act to gather the sub-projects under the same parent, allowing one to build
everything (from the root), or just the ICU proper (no demos, no tools, etc.), or just the tools.

## The Structure and Contents of ICU4J - ICU 74 and later

Expand Down Expand Up @@ -253,6 +261,34 @@ The complete API documentation for ICU4J (javadoc) is available on the ICU4J web
* Unicode Text [Compression](https://unicode-org.github.io/icu-docs/apidoc/released/icu4j/com/ibm/icu/text/UnicodeCompressor.html) & [Decompression](https://unicode-org.github.io/icu-docs/apidoc/released/icu4j/com/ibm/icu/text/UnicodeDecompressor.html) – 2:1 compression on English Unicode text.
* Collation – [Rule-based sorting](https://unicode-org.github.io/icu-docs/apidoc/released/icu4j/com/ibm/icu/text/RuleBasedCollator.html), [Efficient multi-lingual searching](https://unicode-org.github.io/icu-docs/apidoc/released/icu4j/com/ibm/icu/text/StringSearch.html), [Alphabetic indexing](https://unicode-org.github.io/icu-docs/apidoc/released/icu4j/com/ibm/icu/text/AlphabeticIndex.html)

## How to Install and Build - ICU 79 and later

This is identical to ICU 74, but you can run maven commands in the icu root.

And you can always build just the subtree you want with the -f option in maven.

All of this works:
```sh
cd <icu_root>
mvn install
mvn install -f icu4j
mvn install -f icu4j/main
mvn install -f icu4j/main/core

cd icu4j
# this is the same as `-f icu4j` in root
mvn install
# this is the same as `-f icu4j/main` in root
mvn install -f main

cd main
# this is the same as `-f icu4j/main` in root
mvn install
```

Of course, any maven lifecycle phase or goal will work (`clean`, `compile`,
`test`,`package`,`verify`, `install`, etc.)

## How to Install and Build - ICU 74 and later

Using a pre-built version of ICU from Maven Central can be achieved simply by using the artifact
Expand All @@ -272,7 +308,7 @@ Once the JDK and Maven are installed, run the desired Maven target. For example:
[INFO] Scanning for projects...
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Build Order:
[INFO]
[INFO]
[INFO] International Components for Unicode for Java (icu4j-root) [pom]
[INFO] framework [jar]
[INFO] core [jar]
Expand All @@ -289,21 +325,21 @@ Once the JDK and Maven are installed, run the desired Maven target. For example:
[INFO] samples [jar]
[INFO] tools_misc [jar]
[INFO] perf-tests [jar]
[INFO]
[INFO]
[INFO] -----------------------< com.ibm.icu:icu4j-root >-----------------------
[INFO] Building International Components for Unicode for Java (icu4j-root) 74.1-SNAPSHOT [1/16]
[INFO] --------------------------------[ pom ]---------------------------------
[INFO]
[INFO]
[INFO] --- maven-enforcer-plugin:3.3.0:enforce (enforce-maven) @ icu4j-root ---
[INFO] Rule 0: org.apache.maven.enforcer.rules.version.RequireMavenVersion passed
[INFO]
[INFO]

...
...
...

[INFO] Reactor Summary for International Components for Unicode for Java (icu4j-root) 74.1-SNAPSHOT:
[INFO]
[INFO]
[INFO] International Components for Unicode for Java (icu4j-root) SUCCESS [ 0.317 s]
[INFO] framework .......................................... SUCCESS [ 1.125 s]
[INFO] core ............................................... SUCCESS [02:28 min]
Expand All @@ -330,7 +366,7 @@ Once the JDK and Maven are installed, run the desired Maven target. For example:

> :point_right: **Note**: The above output is an example. The numbers are likely to be different with the current version ICU4J.

For more information on how to build or test specific components,
For more information on how to build or test specific components,
or run specific tests,
or to set up your IDE, refer to
[Maven Setup for Java](../../devsetup/java/maven)
Expand Down
Loading