Skip to content

ci: replace battila7/get-version-action (fix set-output & node deprecation)#82

Open
BWibo wants to merge 1 commit into
mainfrom
ci/node24-action-updates
Open

ci: replace battila7/get-version-action (fix set-output & node deprecation)#82
BWibo wants to merge 1 commit into
mainfrom
ci/node24-action-updates

Conversation

@BWibo

@BWibo BWibo commented Jul 8, 2026

Copy link
Copy Markdown
Member

Why

battila7/get-version-action@v2 declares the ancient node12 runtime and internally uses the deprecated set-output workflow command, so it emits both the Node.js 20 and set-output deprecation warnings in the build-push release job:

The set-output command is deprecated and will be disabled soon.
Node.js 20 actions are deprecated. …

All other actions in this repo already run on the Node 24 runtime (checkout@v6, setup-java@v5, gradle/actions/setup-gradle@v6, docker/* v4–v7, short-sha@v4.0), so no version bumps are needed here — this is the only remaining offender.

What

Replace the battila7/get-version-action@v2 step in docker-build-push-release.yml with a small POSIX shell step that derives the version from the release tag and writes to $GITHUB_OUTPUT:

- name: Get release version
  id: release_version
  env:
    REF_NAME: ${{ github.event.release.tag_name || github.ref_name }}
  run: |
    version="${REF_NAME}"
    echo "version=${version}" >> "$GITHUB_OUTPUT"
    echo "version-without-v=${version#v}" >> "$GITHUB_OUTPUT"

The version / version-without-v outputs (the only ones consumed downstream, in the CITYDB_TOOL_VERSION build-arg) are preserved, so the rest of the workflow is unchanged.

Validation

  • YAML parsed; actionlint clean.
  • Shell logic unit-tested for v1.2.3 / 1.2.3 tag forms → correct version / version-without-v.

battila7/get-version-action@v2 declares the ancient node12 runtime and
internally uses the deprecated `set-output` workflow command, so it emits
both the Node.js and set-output deprecation warnings. Replace it with a
small POSIX shell step that derives the version from the release tag and
writes to $GITHUB_OUTPUT, preserving the existing `version` and
`version-without-v` outputs so downstream references are unchanged.

All other actions in this repo already run on the Node 24 runtime, so no
version bumps are required.
@BWibo BWibo self-assigned this Jul 9, 2026
@BWibo BWibo added type: refactor Code restructuring to improve maintainability, readability, or performance ci-build Continuous integration, automated builds, deployment pipelines, or dev workflows dependencies Issues involving external dependencies or upstream development labels Jul 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci-build Continuous integration, automated builds, deployment pipelines, or dev workflows dependencies Issues involving external dependencies or upstream development type: refactor Code restructuring to improve maintainability, readability, or performance

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant