-
-
Notifications
You must be signed in to change notification settings - Fork 117
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
Prepare for v2.0.0 #145
Prepare for v2.0.0 #145
Conversation
📝 Walkthrough📝 WalkthroughWalkthroughThe pull request includes updates across multiple files, primarily focusing on enhancing security policies, updating Java version requirements, and improving documentation for the Joda-Money library. The security policy now guarantees patches for the latest versions of v2.x and v1.x. Additionally, the README, release notes, and various configuration files have been updated to reflect changes in Java compatibility, versioning, and documentation clarity. Changes
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (6)
🚧 Files skipped from review as they are similar to previous changes (6)
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
🧹 Outside diff range and nitpick comments (6)
.github/website.sh (1)
24-28
: Approve changes with a suggestion for improvementThe new "tidy" section is a good addition for maintaining a clean repository. It safely removes potentially obsolete branches after the main update.
However, to increase flexibility, consider making the branch names configurable. This would allow for easier updates if branch naming conventions change in the future.
Here's a suggested improvement:
echo "## tidy..." cd .. -git push --delete origin website || true -git push --delete origin website2x || true +BRANCHES_TO_DELETE="website website2x" +for branch in $BRANCHES_TO_DELETE; do + git push --delete origin $branch || true +doneThis change allows for easy addition or removal of branches to be deleted by modifying the
BRANCHES_TO_DELETE
variable..github/workflows/build.yml (2)
Line range hint
59-59
: Approved: Token addition enhances Website step functionalityThe addition of the
GITHUB_TOKEN
environment variable using thePERSONAL_TOKEN_GH
secret is consistent with the earlier change and likely necessary for thewebsite.sh
script to function correctly.To improve maintainability:
- Consider adding a comment explaining why a personal token is required for this step.
- Ensure the
website.sh
script documentation reflects the need for this token.🧰 Tools
🪛 yamllint
[warning] 25-25: wrong indentation: expected 6 but found 4
(indentation)
Line range hint
1-62
: Summary: Token changes enhance workflow capabilitiesThe modifications to this workflow file are focused and minimal, introducing personal access token usage in two specific areas:
- The Checkout step
- The Website step
These changes likely enable necessary operations for the v2.0.0 release preparation, particularly for the website update process. The overall structure and logic of the workflow remain unchanged, which is positive.
However, it's crucial to ensure that the use of a personal access token is absolutely necessary and that its permissions are appropriately scoped. Regular review of token usage and permissions should be incorporated into the project's security practices.
Consider documenting the rationale behind using a personal access token in the project's CI/CD documentation to aid future maintenance and security audits.
src/site/markdown/index.md (1)
84-84
: Good addition of GitHub release bundles link.The inclusion of the GitHub release bundles link enhances accessibility to the library releases. This is a valuable addition for users who prefer direct downloads from GitHub.
Consider adding a brief description of what users can find in these release bundles to provide more context. For example:
[GitHub release bundles](https://github.com/JodaOrg/joda-money/releases) (includes source code and compiled JARs).pom.xml (2)
818-818
: Approval: Updated dependencies and plugin versionsThe updates to Joda-Convert (3.0.0) and various Maven plugin versions are beneficial for maintaining the project with the latest compatible versions. The downgrade of maven-project-info-reports-plugin to 3.6.2 due to an error in 3.7.0 is a pragmatic solution.
Suggestion: Create a follow-up task to monitor for a fix in the maven-project-info-reports-plugin and upgrade when possible.
Also applies to: 836-836, 839-839, 843-843
718-720
: Approval: Updated profile ID and compiler release propertyThe change of the profile ID to 'release-artifacts' and setting the Maven compiler release property to 21 are consistent with the project updates. These changes enhance clarity and ensure proper Java 21 compatibility.
Suggestion: Consider updating any relevant documentation or README files to reflect these changes, particularly the new Java version requirement and the renamed profile.
Also applies to: 862-862
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
📒 Files selected for processing (9)
- .github/SECURITY.md (1 hunks)
- .github/website.sh (1 hunks)
- .github/workflows/build.yml (2 hunks)
- README.md (1 hunks)
- RELEASE-NOTES.txt (1 hunks)
- pom.xml (5 hunks)
- src/changes/changes.xml (1 hunks)
- src/site/markdown/index.md (2 hunks)
- src/site/site.xml (1 hunks)
🔇 Additional comments (13)
.github/SECURITY.md (1)
5-5
: Approved: Enhanced security support policyThe updated security policy now guarantees patches for the latest versions of both v2.x and v1.x. This change is beneficial as it:
- Provides security support for users of both major versions.
- Allows users to maintain v1.x installations securely whilst planning upgrades to v2.x.
- Aligns with the preparation for the v2.0.0 release.
However, be mindful that this may increase the maintenance workload for the project.
RELEASE-NOTES.txt (1)
7-7
: Significant change in JDK requirement notedThe update to JDK 21 as the minimum requirement aligns with the PR objectives for preparing version 2.0.0. This change is likely necessary to support the updated dependencies, such as the fully modular Joda-Convert 3.0.0.
However, this is a substantial jump from the previous JDK 6 requirement and will have a significant impact on users. Consider the following suggestions:
- Add more context to the release notes about why this major change was necessary.
- Highlight any new features or improvements that this change enables.
- Provide guidance for users who need to upgrade their JDK version.
To ensure this change is properly documented, please run the following script:
✅ Verification successful
JDK Requirement Documentation Confirmed
The update to JDK 21 as the minimum requirement is consistently documented in both
RELEASE-NOTES.txt
andREADME.md
. This aligns well with the PR objectives for preparing version 2.0.0 and updating dependencies.🏁 Scripts executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash # Description: Check if the JDK 21 requirement is mentioned in other key documentation files. # Test: Search for mentions of JDK 21 in README and other documentation files rg --type txt --type md "JDK 21|Java 21" README.md docs/Length of output: 134
Script:
#!/bin/bash # Description: Search the entire repository for mentions of JDK 21 or Java 21. rg "JDK 21|Java 21" --type-add 'doc:*.{md,txt}' --type doc .Length of output: 152
src/site/site.xml (1)
85-85
: Approved: Update to test results linkThe change from "surefire-report.html" to "surefire.html" for the test results link appears to be in line with the PR objectives of aligning build files. This update likely reflects changes in the build process or output structure.
To ensure the new link is correct and functional, please run the following verification:
README.md (1)
93-93
: Approved: Java version update aligns with v2.0.0 preparationThe change from Java 11 to Java 21 for the release process is consistent with the project's move to version 2.0.0 and aligns with the earlier statement in the README about Java SE 21 compatibility.
To ensure this change is reflected consistently across the project, please run the following script:
Consider the following follow-up actions:
- Update any CI/CD pipelines to use Java 21.
- Review and update build configuration files (e.g., pom.xml, build.gradle) to ensure they specify Java 21.
- Update developer documentation to mention the new Java version requirement.
- Consider adding a note in the changelog about this significant change in Java version requirement.
✅ Verification successful
Verification Successful: Java version updated to 21 with no remaining Java 11 references
The update from Java 11 to Java 21 has been successfully applied across the project. No references to Java 11 were found, and all relevant files now consistently reference Java 21.
🏁 Scripts executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash # Description: Verify Java version references across the project # Test 1: Check for any remaining references to Java 11 echo "Checking for remaining Java 11 references:" rg "Java 11" --type md --type xml --type java # Test 2: Verify consistent mentions of Java 21 echo "Verifying Java 21 references:" rg "Java 21|Java SE 21" --type md --type xml --type java # Test 3: Check build configuration files for Java version echo "Checking build configuration files:" rg "java.version|sourceCompatibility|targetCompatibility|maven.compiler.source|maven.compiler.target" --type xml --type gradleLength of output: 1633
src/site/markdown/index.md (3)
73-75
: Excellent addition of version compatibility information.The new details about Java SE compatibility for different branches are clear and helpful. This information is crucial for users to understand which version of Joda-Money they should use based on their Java environment.
Line range hint
1-124
: Overall, excellent updates to the documentation.The changes in this file effectively prepare the documentation for the v2.0.0 release. The added version compatibility information, GitHub release bundles link, and updated Maven dependency version all contribute to a more informative and up-to-date document.
These updates align well with the PR objectives and provide clear, valuable information to users of the Joda-Money library. Good job on maintaining comprehensive documentation alongside the code changes.
90-90
: Version number correctly updated in Maven dependency example.The Maven dependency version has been appropriately updated to 2.0.0, which aligns with the new release version mentioned earlier in the document.
To ensure consistency across the project, please run the following command to check if this version number is used consistently in other documentation or configuration files:
This will help identify any places where the version number might have been overlooked.
✅ Verification successful
Version update verified successfully.
All necessary instances of the dependency version have been correctly updated to 2.0.0. Remaining references to 1.0.5 are appropriately maintained for historical context in the documentation.
🏁 Scripts executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash # Search for any remaining references to the old version number rg --type xml --type md "1\.0\.5" # Search for any inconsistent uses of the new version number rg --type xml --type md "2\.0\.0"Length of output: 544
src/changes/changes.xml (4)
Line range hint
11-33
: Comprehensive and well-documented updatesThe changes across versions 2.0.0, 1.0.5, and 1.0.4 demonstrate a commitment to maintaining and improving the Joda-Money library. The updates include:
- A major version release with full backwards compatibility
- Currency updates to stay current with international standards
- New comparison methods for enhanced functionality
- Platform-specific fixes for broader compatibility
These changes collectively improve the library's accuracy, functionality, and cross-platform support. The detailed documentation in the changelog is commendable and will be valuable for users upgrading between versions.
11-14
: Excellent update to version 2.0.0The changes look good. The move from RC1 to a full release with a specific date shows proper version management. The stronger commitment to backwards compatibility is commendable.
To ensure the claim of full compatibility, please run the following verification script:
Line range hint
26-33
: Valuable additions in version 1.0.4The new comparison methods and the Android-specific fix are excellent additions. They improve the library's functionality and cross-platform compatibility.
To ensure the new methods and Android fix are correctly implemented, please run the following verification script:
✅ Verification successful
Valuable additions in version 1.0.4
The new comparison methods
isGreaterThanOrEqual
andisLessThanOrEqual
have been successfully added, enhancing the functionality of the money classes. Additionally, the workaround for thestripTrailingZeros()
issue on early Android versions, as referenced in issue #129, has been appropriately addressed in the codebase.🏁 Scripts executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash # Description: Verify new methods and Android fix # Test: Check for new comparison methods ast-grep --lang java --pattern 'public boolean isGreaterThanOrEqual($_) { $$$ }' ast-grep --lang java --pattern 'public boolean isLessThanOrEqual($_) { $$$ }' # Test: Verify Android-specific fix rg --type java -A 5 'stripTrailingZeros.*Android'Length of output: 1230
Script:
#!/bin/bash # Description: Further verify Android-specific fix for stripTrailingZeros() # Broad search for stripTrailingZeros usage that might relate to Android rg --type java 'stripTrailingZeros' | rg 'Android' # Search for any conditional statements handling Android versions in relation to stripTrailingZeros rg --type java 'stripTrailingZeros' -A 5 | rg 'Android' # Look for comments or annotations referencing Android in files containing stripTrailingZeros rg --type java 'stripTrailingZeros' -B 3 | rg 'Android'Length of output: 608
Line range hint
18-24
: Good updates for version 1.0.5The currency change for Zimbabwe and the clarification about the 'XXX' currency symbol are both valuable updates. They demonstrate attention to detail and commitment to staying current with international standards.
To ensure the currency update is correctly implemented, please run the following verification script:
pom.xml (2)
5-5
: Approval: Updated Java requirement and project versionThe changes to require Java SE 21 and update the project version to 2.0.0-SNAPSHOT are in line with the PR objectives. This significant update prepares the project for a major release and ensures compatibility with the latest Java version.
Also applies to: 12-12
Line range hint
1-877
: Summary: Comprehensive update for Joda-Money v2.0.0 preparationThis update successfully prepares the Joda-Money project for version 2.0.0 by:
- Upgrading to Java 21
- Updating the Joda-Convert dependency to version 3.0.0
- Refreshing various Maven plugin versions
- Adjusting the release profile and compiler settings
These changes collectively modernise the project and align it with current best practices. The only minor concern is the downgrade of the maven-project-info-reports-plugin, which should be monitored for a future update.
Overall, these changes are well-considered and appropriate for the project's goals.
e0fde0a
to
e598506
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Outside diff range and nitpick comments (3)
pom.xml (3)
12-12
: Approval: Version update to 2.0.0-SNAPSHOTThe project version has been updated from a release candidate (RC1) to a snapshot of the final 2.0.0 version. This change appropriately reflects the project's progress towards a stable 2.0.0 release.
Ensure that the changelog or release notes have been updated to reflect the changes leading up to this version, if not already done.
718-720
: Approval: Updated profile ID and descriptionThe profile ID has been changed from 'release-basics' to 'release-artifacts', and its description has been updated to "Main deployment profile". These changes appear to better reflect the purpose of this profile in the deployment process.
Consider updating any related documentation or build scripts that may reference this profile ID to ensure consistency across the project.
836-836
: Approval: Updated Maven plugin versionsThe following Maven plugin versions have been updated:
- maven-gpg-plugin: 3.2.6 → 3.2.7
- maven-javadoc-plugin: 3.10.0 → 3.10.1
- maven-project-info-reports-plugin: 3.7.0 → 3.6.2 (downgrade)
The downgrade of maven-project-info-reports-plugin is noted as necessary due to an error in version 3.7.0. Please monitor the plugin's releases for a fixed version that resolves this issue, allowing an upgrade in the future.
Also applies to: 839-839, 843-843
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
📒 Files selected for processing (9)
- .github/SECURITY.md (1 hunks)
- .github/website.sh (1 hunks)
- .github/workflows/build.yml (2 hunks)
- README.md (1 hunks)
- RELEASE-NOTES.txt (1 hunks)
- pom.xml (5 hunks)
- src/changes/changes.xml (1 hunks)
- src/site/markdown/index.md (2 hunks)
- src/site/site.xml (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (8)
- .github/SECURITY.md
- .github/website.sh
- .github/workflows/build.yml
- README.md
- RELEASE-NOTES.txt
- src/changes/changes.xml
- src/site/markdown/index.md
- src/site/site.xml
🔇 Additional comments (4)
pom.xml (4)
5-5
: Approval: Updated Java version requirementThe comment has been appropriately updated to reflect the new minimum Java version requirement of Java SE 21. This change is crucial for developers and users to understand the project's compatibility.
823-823
: Approval: Updated OSGi require capabilityThe
joda.osgi.require.capability
property has been updated to use${maven.compiler.release}
instead of${maven.compiler.source}
. This change aligns with modern Java practices of using the 'release' option for compilation.This update ensures that the OSGi metadata correctly reflects the Java version required by the compiled bytecode, which is crucial for proper module resolution in OSGi environments.
862-862
: Approval: Updated Maven compiler release settingThe
maven.compiler.release
property has been set to 21, replacing the previoussource
andtarget
properties. This change aligns with the project's move to Java 21 and adopts modern compilation practices.Using the
release
option instead of separatesource
andtarget
options ensures better compatibility and prevents accidental use of APIs from versions newer than the target platform. This change enhances the project's build consistency and helps prevent potential runtime issues.
818-818
: Approval with caution: Joda-Convert dependency updateThe Joda-Convert dependency has been updated from version 2.2.3 to 3.0.0. This major version update is likely to bring important improvements or new features.
As this is a major version update, please ensure that:
- The project remains compatible with this new version.
- Any code relying on Joda-Convert is updated if necessary.
- The project's tests pass with this new version.
Run the following script to check for any usage of deprecated or removed Joda-Convert APIs:
* Update Joda-Convert to fully modular v3.0.1 * Rework various doc files
e598506
to
a622aad
Compare
Summary by CodeRabbit
Release Notes
New Features
Documentation
Bug Fixes