Skip to content

Maven central release#119

Open
javier-godoy wants to merge 7 commits into
masterfrom
maven-central-release
Open

Maven central release#119
javier-godoy wants to merge 7 commits into
masterfrom
maven-central-release

Conversation

@javier-godoy

@javier-godoy javier-godoy commented Jun 5, 2026

Copy link
Copy Markdown
Member

Summary by CodeRabbit

  • Chores
    • Updated Maven release tooling to a newer release version with improved release configuration
    • Added profiles to support GPG artifact signing and Sonatype Central publishing
    • Adjusted when source artifacts are attached in the build lifecycle
    • Added project URL metadata to project configuration

@coderabbitai

coderabbitai Bot commented Jun 5, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: cad083e9-014a-4a61-8935-bf7d00db479b

📥 Commits

Reviewing files that changed from the base of the PR and between 1e7edcb and 2ff93a9.

📒 Files selected for processing (1)
  • pom.xml
🚧 Files skipped from review as they are similar to previous changes (1)
  • pom.xml

Walkthrough

POM updated: adds project URL, upgrades maven-release-plugin to 3.0.1 (bound to release profile), moves source attachment to package, and adds release and env-driven gpg profiles for Sonatype Central publishing and GPG signing.

Changes

Maven Central Publishing Setup

Layer / File(s) Summary
Project metadata and release plugin configuration
pom.xml
Project url added. maven-release-plugin upgraded to 3.0.1 and configured with releaseProfiles = release.
Source attachment phase adjustment
pom.xml
In directory profile, maven-source-plugin execution for attach-sources moved from verify to package.
Release and GPG signing profiles
pom.xml
New release profile enables central-publishing-maven-plugin extension; new gpg profile activates on MAVEN_GPG_PASSPHRASE and configures maven-gpg-plugin to sign artifacts during verify.

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~45 minutes

Possibly related issues

  • FlowingCode/YearMonthCalendarAddon#120 — The issue requests including directory in releaseProfiles; this PR adds releaseProfiles = release, which is directly related to releaseProfile behavior mentioned in that issue.

Suggested reviewers

  • mlopezFC
🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'Maven central release' directly and concisely summarizes the main objective of the pull request, which is to prepare the project for publishing to Maven Central Repository.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch maven-central-release

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@javier-godoy

Copy link
Copy Markdown
Member Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jun 8, 2026

Copy link
Copy Markdown
✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@pom.xml`:
- Around line 179-182: The release profile currently activates only the profile
identified by "release" via the releaseProfiles element, which omits the
"directory" profile that declares the maven-source-plugin and
maven-javadoc-plugin; update the releaseProfiles configuration (the
<releaseProfiles> value) to include both "release" and "directory" so that
running release:perform also activates the "directory" profile and produces
source and javadoc JARs required by Maven Central.
- Around line 530-556: Update the maven-gpg-plugin version in the gpg profile:
locate the <profile> with <id>gpg</id> and the plugin element for
org.apache.maven.plugins:maven-gpg-plugin (artifactId maven-gpg-plugin) and
change its <version> from 3.2.7 to 3.2.8 so the profile uses the latest plugin
release.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: f545b3e1-af53-4230-860e-57bf8e5d6a2f

📥 Commits

Reviewing files that changed from the base of the PR and between a6fdbcd and 1e7edcb.

📒 Files selected for processing (1)
  • pom.xml

Comment thread pom.xml
Comment on lines +179 to +182
<version>3.0.1</version>
<configuration>
<releaseProfiles>release</releaseProfiles>
</configuration>

@coderabbitai coderabbitai Bot Jun 8, 2026

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major | ⚡ Quick win

Include directory profile in releaseProfiles for sources and javadoc.

The release profile only contains the publishing plugin, but Maven Central requires source and javadoc JARs. Those plugins are defined in the directory profile (lines 296-331). When release:perform runs, it will only activate the release profile, causing Maven Central validation to fail due to missing artifacts.

🛠️ Proposed fix
 				<configuration>
-					<releaseProfiles>release</releaseProfiles>
+					<releaseProfiles>release,directory</releaseProfiles>
 				</configuration>
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
<version>3.0.1</version>
<configuration>
<releaseProfiles>release</releaseProfiles>
</configuration>
<configuration>
<releaseProfiles>release,directory</releaseProfiles>
</configuration>
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@pom.xml` around lines 179 - 182, The release profile currently activates only
the profile identified by "release" via the releaseProfiles element, which omits
the "directory" profile that declares the maven-source-plugin and
maven-javadoc-plugin; update the releaseProfiles configuration (the
<releaseProfiles> value) to include both "release" and "directory" so that
running release:perform also activates the "directory" profile and produces
source and javadoc JARs required by Maven Central.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@coderabbitai Please create an issue about this.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧩 Analysis chain

🏁 Script executed:

gh issue create \
  --repo FlowingCode/YearMonthCalendarAddon \
  --assignee javier-godoy \
  --title "Include 'directory' profile in releaseProfiles for Maven Central source and javadoc JARs" \
  --body "## Problem

When \`release:perform\` is executed, Maven activates only the profiles listed in \`<releaseProfiles>\`. Currently, only the \`release\` profile is listed (see \`pom.xml\`), which activates the \`central-publishing-maven-plugin\`.

However, the \`maven-source-plugin\` and \`maven-javadoc-plugin\` executions that produce the required source and javadoc JARs are declared in the **\`directory\`** profile. Because that profile is not activated during the release, Maven Central validation will fail due to missing source/javadoc artifacts.

## Expected behavior

The \`<releaseProfiles>\` configuration should include both \`release\` and \`directory\` so that running \`release:perform\` also activates the \`directory\` profile and produces all artifacts required by Maven Central.

## References

- Pull request: https://github.com/FlowingCode/YearMonthCalendarAddon/pull/119
- Review comment: https://github.com/FlowingCode/YearMonthCalendarAddon/pull/119#discussion_r3373145159

_Reported by `@coderabbitai` on behalf of `@javier-godoy._`"

Length of output: 1367



@javier-godoy, the issue has been created and assigned to you: https://github.com/FlowingCode/YearMonthCalendarAddon/issues/120

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This comment has been deferred for later analysis.

Comment thread pom.xml
@sonarqubecloud

sonarqubecloud Bot commented Jun 8, 2026

Copy link
Copy Markdown

@javier-godoy javier-godoy marked this pull request as ready for review June 8, 2026 20:19
@javier-godoy javier-godoy requested review from paodb and scardanzan June 8, 2026 20:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: To Do

Development

Successfully merging this pull request may close these issues.

1 participant