ci: github action for automated releasing - #440
Conversation
bednar
left a comment
There was a problem hiding this comment.
Thanks for your PR. There are a few requirements which has to be satisfied:
| </servers> | ||
| </settings> | ||
| EOF | ||
| git config --global user.email "test@example.com" |
There was a problem hiding this comment.
Change this to something more real.
| <groupId>com.influxdb</groupId> | ||
| <artifactId>influxdb3-java</artifactId> | ||
| <version>1.12.0-SNAPSHOT</version> | ||
| <version>1.12.0</version> |
| <artifactId>influxdb3-java</artifactId> | ||
| <packaging>jar</packaging> | ||
| <version>1.12.0-SNAPSHOT</version> | ||
| <version>1.12.0</version> |
| <developerConnection>scm:git:https://github.com/InfluxCommunity/influxdb3-java.git</developerConnection> | ||
| <url>https://github.com/InfluxCommunity/influxdb3-java/tree/main</url> | ||
| <tag>HEAD</tag> | ||
| <tag>v1.12.0</tag> |
| <groupId>com.influxdb</groupId> | ||
| <artifactId>influxdb3-java</artifactId> | ||
| <version>1.11.0</version> | ||
| <version>1.12.0</version> |
| ``` | ||
| $ gpg2 --keyserver keyserver.ubuntu.com --search-keys REDACTED_KEY_ID | ||
| gpg: data source: http://185.125.188.27:11371 | ||
| (1) karel-rehor@users.noreply.github.com |
There was a problem hiding this comment.
| (1) karel-rehor@users.noreply.github.com | |
| (1) your-user@users.noreply.github.com |
| (1) karel-rehor@users.noreply.github.com | ||
| 263 bit EDDSA key REDACTED, created: 2026-09-03 | ||
| Keys 1-1 of 1 for "REDACTED_KEY_ID". Enter number(s), N)ext, or Q)uit > 1 | ||
| gpg: key REDACTED: "karel-rehor@users.noreply.github.com" not changed |
There was a problem hiding this comment.
| gpg: key REDACTED: "karel-rehor@users.noreply.github.com" not changed | |
| gpg: key REDACTED: "your-user@users.noreply.github.com" not changed |
| ----------------------------- | ||
| pub ed25519 2026-07-27 [SC] [expires: 2029-07-26] | ||
| KEY_ID_REDACTED | ||
| uid [ultimate] karel-rehor@users.noreply.github.com |
There was a problem hiding this comment.
| uid [ultimate] karel-rehor@users.noreply.github.com | |
| uid [ultimate] your-user@users.noreply.github.com |
| $ gpg2 --list-keys KEY_ID_REDACTED | ||
| pub ed25519 2026-07-27 [SC] [expires: 2029-07-26] | ||
| KEY_ID_REDACTED | ||
| uid [ultimate] karel-rehor@users.noreply.github.com |
There was a problem hiding this comment.
| uid [ultimate] karel-rehor@users.noreply.github.com | |
| uid [ultimate] your-user@users.noreply.github.com |
| (1) karel-rehor@users.noreply.github.com | ||
| 263 bit EDDSA key REDACTED, created: 2026-07-27 | ||
| Keys 1-1 of 1 for "KEY_ID_REDACTED". Enter number(s), N)ext, or Q)uit > 1 | ||
| gpg: key REDACTED: "karel-rehor@users.noreply.github.com" not changed |
There was a problem hiding this comment.
| gpg: key REDACTED: "karel-rehor@users.noreply.github.com" not changed | |
| gpg: key REDACTED: "your-user@users.noreply.github.com" not changed |
bednar
left a comment
There was a problem hiding this comment.
Please address the selected inline comments before merge.
| mvn versions:set -DnextSnapshot=true -DnextSnapshotIndexToIncrement=2 | ||
| sed -i "1s/^/## ${NEXT_RELEASE:1} [unreleased]\n\n/" CHANGELOG.md | ||
| sed -i -e "s/<version>${RELEASE_TAG_NAME:1}<\/version>/<version>${NEXT_RELEASE:1}-SNAPSHOT<\/version>/" examples/pom.xml | ||
| git add pom.xml CHANGELOG.md |
There was a problem hiding this comment.
Please also stage examples/pom.xml here. The previous command rewrites its dependency from the released version to ${NEXT_RELEASE:1}-SNAPSHOT, but this git add omits the file, so the pushed next-cycle branch retains the released dependency version and the preparation is incomplete.
| RC_OR_BETA=false | ||
| IS_SNAPSHOT=false | ||
|
|
||
| FAILURE_BOILERPLATE="Please delete the tag ${CIRCLE_TAG} and the related release, and start again." |
There was a problem hiding this comment.
Please replace ${CIRCLE_TAG} with the GitHub Actions release tag, such as ${RELEASE_TAG_NAME}. This script runs in GitHub Actions, so ${CIRCLE_TAG} is unset; every failure message currently says to delete an empty tag, which makes the recovery instructions unusable.
| EXAMPLE_POM_XML_PATH="${PROJECT_DIR}/examples/pom.xml" | ||
|
|
||
| RELEASE_NUM="" | ||
| NEXT_RELEASE_NUM="" |
There was a problem hiding this comment.
The declarations NEXT_RELEASE_NUM, NEXT_RELEASE_BRANCH_BASE, RC_OR_BETA, and IS_SNAPSHOT are never read. Please remove them or wire them into the implementation; they are dead code and trigger ShellCheck warnings.
| if [ "${SCM_TAG}" != "${RELEASE_TAG_NAME}" ] | ||
| then | ||
| printf "SCM_TAG %s in pom.xml does not match tag %s" "${SCM_TAG}" "${RELEASE_TAG_NAME}" | ||
| prinf "%s\n" "${FAILURE_BOILERPLATE}" |
There was a problem hiding this comment.
prinf is a typo for printf. With set -e, this branch exits on the command-not-found error before printing the intended recovery message. Please fix the typo.
Proposed Changes
Sets up automated releasing.
nexus-staging-maven-pluginwith recommendedcentral-publishing-maven-pluginmaven-release.ymlon-release.shscript which ensures values inpom.xmlfiles and documentation match the release version and tag.pom.xml1.11.0 is incremented to 1.12.0-SNAPSHOT.Note this requires up-to-date values for action secrets
Checklist
[ ] A test has been added if appropriateN.A.