Skip to content

Commit

Permalink
Prepare for v2.0.0
Browse files Browse the repository at this point in the history
* Update Joda-Convert to fully modular v3.0.0
* Bring build files in line with Joda-Convert
* Use release instead of source/target in pom.xml
  • Loading branch information
jodastephen committed Oct 5, 2024
1 parent 1ea4ef3 commit e598506
Show file tree
Hide file tree
Showing 9 changed files with 29 additions and 23 deletions.
2 changes: 1 addition & 1 deletion .github/SECURITY.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

## Supported Versions

If a security issue occurs, only the latest version is guaranteed to be patched.
If a security issue occurs, only the latest versions of v2.x and v1.x are guaranteed to be patched.

## Reporting a Vulnerability

Expand Down
5 changes: 5 additions & 0 deletions .github/website.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,9 @@ git commit --message "Update joda-money from CI: $GITHUB_ACTION"
echo "## push..."
git push origin main

echo "## tidy..."
cd ..
git push --delete origin website || true
git push --delete origin website2x || true

echo "## done"
6 changes: 4 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v4
with:
token: ${{ secrets.PERSONAL_TOKEN_GH }}

- name: Set up JDK
uses: actions/setup-java@v4
Expand All @@ -43,14 +45,14 @@ jobs:
uses: github/codeql-action/init@v3
with:
languages: java

- name: Maven build
run: |
mvn install site
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3

- name: Website
if: github.event_name == 'push' && (startsWith(github.ref, 'refs/tags/website') || startsWith(github.ref, 'refs/tags/v'))
env:
Expand Down
3 changes: 1 addition & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -90,8 +90,7 @@ Tidelift will coordinate the fix and disclosure.

* Update version (index.md, changes.xml)
* Commit and push
* In an admin window `gpg-connect-agent -v`
* Switch to Java 11
* Switch to Java 21
* `mvn clean release:clean release:prepare release:perform`
* `git fetch`
* Website will be built and released by GitHub Actions
2 changes: 1 addition & 1 deletion RELEASE-NOTES.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Joda-Money
Joda-Money is a monetary library that fills the gap in the JDK
by providing a Money class and associated formatting.

The release runs on JDK 6 or later.
The release runs on JDK 21 or later.

See https://www.joda.org/joda-money/changes-report.html for changes

Expand Down
21 changes: 10 additions & 11 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">

<!-- ==================================================================== -->
<!-- Build requires Java SE 11 or later -->
<!-- Build requires Java SE 21 or later -->
<!-- ==================================================================== -->
<modelVersion>4.0.0</modelVersion>
<groupId>org.joda</groupId>
<artifactId>joda-money</artifactId>
<packaging>jar</packaging>
<name>Joda-Money</name>
<version>2.0.0-RC1-SNAPSHOT</version>
<version>2.0.0-SNAPSHOT</version>
<description>Money representation and formatting, compatible with Java 21+</description>
<url>https://www.joda.org/joda-money/</url>

Expand Down Expand Up @@ -715,9 +715,9 @@
</plugins>
</build>
</profile>
<!-- Base deployment profile, activated by -Doss.repo -->
<!-- Main deployment profile, activated by -Doss.repo -->
<profile>
<id>release-basics</id>
<id>release-artifacts</id>
<activation>
<property>
<name>oss.repo</name>
Expand Down Expand Up @@ -815,12 +815,12 @@
<properties>
<!-- Dependencies -->
<assertj.version>3.26.3</assertj.version>
<joda-convert.version>2.2.3</joda-convert.version>
<joda-convert.version>3.0.0</joda-convert.version>
<junit.version>5.11.0</junit.version>

<!-- Common control parameters -->
<joda.osgi.packages>org.joda.money.*</joda.osgi.packages>
<joda.osgi.require.capability>osgi.ee;filter:="(&amp;(osgi.ee=JavaSE)(version=${maven.compiler.source}))"</joda.osgi.require.capability>
<joda.osgi.require.capability>osgi.ee;filter:="(&amp;(osgi.ee=JavaSE)(version=${maven.compiler.release}))"</joda.osgi.require.capability>
<joda.nexus.auto.release>true</joda.nexus.auto.release>

<!-- Plugin version numbers -->
Expand All @@ -833,14 +833,14 @@
<maven-deploy-plugin.version>3.1.3</maven-deploy-plugin.version>
<maven-dependency-plugin.version>3.8.0</maven-dependency-plugin.version>
<maven-enforcer-plugin.version>3.5.0</maven-enforcer-plugin.version>
<maven-gpg-plugin.version>3.2.6</maven-gpg-plugin.version>
<maven-gpg-plugin.version>3.2.7</maven-gpg-plugin.version>
<maven-install-plugin.version>3.1.3</maven-install-plugin.version>
<maven-jar-plugin.version>3.4.2</maven-jar-plugin.version>
<maven-javadoc-plugin.version>3.10.0</maven-javadoc-plugin.version>
<maven-javadoc-plugin.version>3.10.1</maven-javadoc-plugin.version>
<maven-jxr-plugin.version>3.5.0</maven-jxr-plugin.version>
<maven-plugin-plugin.version>3.15.0</maven-plugin-plugin.version>
<maven-pmd-plugin.version>3.25.0</maven-pmd-plugin.version>
<maven-project-info-reports-plugin.version>3.7.0</maven-project-info-reports-plugin.version>
<maven-project-info-reports-plugin.version>3.6.2</maven-project-info-reports-plugin.version><!-- 3.7.0 has error -->
<maven-release-plugin.version>3.1.1</maven-release-plugin.version>
<maven-repository-plugin.version>2.4</maven-repository-plugin.version>
<maven-resources-plugin.version>3.3.1</maven-resources-plugin.version>
Expand All @@ -859,8 +859,7 @@
<spotbugs-maven-plugin.version>4.8.6.4</spotbugs-maven-plugin.version>

<!-- Properties for maven-compiler-plugin -->
<maven.compiler.source>21</maven.compiler.source>
<maven.compiler.target>21</maven.compiler.target>
<maven.compiler.release>21</maven.compiler.release>
<maven.compiler.fork>true</maven.compiler.fork>

<!-- Properties for maven-javadoc-plugin -->
Expand Down
4 changes: 2 additions & 2 deletions src/changes/changes.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@
<body>

<!-- types are add, fix, remove, update -->
<release version="2.0.0-RC1" date="SNAPSHOT" description="Version 2.0.0-RC1">
<release version="2.0.0" date="2024-10-05" description="Version 2.0.0">
<action dev="jodastephen" type="add">
Major version based on Java SE 21.
Intended to be effectively compatible with v1.x.
Intended to be fully compatible with v1.x.
</action>
</release>
<release version="1.0.5" date="2024-08-25" description="v1.0.5">
Expand Down
7 changes: 4 additions & 3 deletions src/site/markdown/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,9 +70,9 @@ As a flavour of Joda-Money, here is some example code:

## <i></i> Releases

The 2.x branch is compatible with Java SE 21 or later.
The 2.x branch (v2.0.0) is compatible with Java SE 21 or later.

The 1.x branch is compatible with Java SE 8 or later.
The 1.x branch (v1.0.5) is compatible with Java SE 8 or later.

v2.x releases are compatible with v1.x releases - except for the Java SE version and `module-info.class` file.

Expand All @@ -81,12 +81,13 @@ There is a *compile-time* dependency on [Joda-Convert](https://www.joda.org/joda
but this is not required at runtime thanks to the magic of annotations.

Available in [Maven Central](https://search.maven.org/search?q=g:org.joda%20AND%20a:joda-money&core=gav).
[GitHub release bundles](https://github.com/JodaOrg/joda-money/releases).

```xml
<dependency>
<groupId>org.joda</groupId>
<artifactId>joda-money</artifactId>
<version>1.0.5</version>
<version>2.0.0</version>
</dependency>
```

Expand Down
2 changes: 1 addition & 1 deletion src/site/site.xml
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@
<menu name="Development">
<item name="GitHub" href="https://github.com/JodaOrg/joda-money"/>
<item name="Bugs/Issues" href="https://github.com/JodaOrg/joda-money/issues"/>
<item name="Test results" href="surefire-report.html"/>
<item name="Test results" href="surefire.html"/>
<item name="Test coverage" href="/jacoco/index.html"/>
</menu>

Expand Down

0 comments on commit e598506

Please sign in to comment.