Skip to content

fix(release): use docker version in commit messages for docker-only releases#34489

Open
wmorland wants to merge 1 commit intonrwl:masterfrom
wmorland:release-dockerVersion
Open

fix(release): use docker version in commit messages for docker-only releases#34489
wmorland wants to merge 1 commit intonrwl:masterfrom
wmorland:release-dockerVersion

Conversation

@wmorland
Copy link

@wmorland wmorland commented Feb 17, 2026

Current Behavior

When performing a docker-only release (newVersion is null, dockerVersion is set), createCommitMessageValues() failed to include the version in commit messages. Three code paths passed null as the version or skipped docker-only projects entirely:

  • Single fixed group: passed null to ReleaseVersion constructor
  • Multi-group independent projects: skipped docker-only projects from bullet points
  • Multi-group fixed groups: skipped docker-only groups from bullet points

Expected Behavior

Apply fallback pattern (newVersion ?? dockerVersion) where the code is just checking newVersion currently.

Also fix createGitTagValues() dockerVersion guards to use loose inequality (!= null) instead of strict (!== null), since dockerVersion is typed as string | undefined, not string | null.

Testing

Added test cases to packages/nx/src/command-line/release/utils/shared.spec.ts

  • npx nx format
  • npx nx run nx:test
  • pnpm check-commit

Related Issue(s)

I searched but could not find any issues filed for this. Please let me know if it is necessary to file one.

…eleases

When performing a docker-only release (newVersion is null, dockerVersion is set), createCommitMessageValues() failed to include the version in commit messages. Three code paths passed null as the version or skipped docker-only projects entirely:

- Single fixed group: passed null to ReleaseVersion constructor
- Multi-group independent projects: skipped docker-only projects from bullet points
- Multi-group fixed groups: skipped docker-only groups from bullet points

Apply the same fallback pattern (newVersion ?? dockerVersion) that was already used for the single-independent-project case.

Also fix createGitTagValues() dockerVersion guards to use loose inequality (!= null) instead of strict (!== null), since dockerVersion is typed as string | undefined, not string | null.
@wmorland wmorland requested review from a team and Coly010 as code owners February 17, 2026 18:50
@wmorland wmorland requested a review from MaxKless February 17, 2026 18:50
@netlify
Copy link

netlify bot commented Feb 17, 2026

Deploy Preview for nx-docs canceled.

Name Link
🔨 Latest commit 53f460d
🔍 Latest deploy log https://app.netlify.com/projects/nx-docs/deploys/6994b88005ecd90008705d34

@netlify
Copy link

netlify bot commented Feb 17, 2026

Deploy Preview for nx-dev canceled.

Name Link
🔨 Latest commit 53f460d
🔍 Latest deploy log https://app.netlify.com/projects/nx-dev/deploys/6994b880a0b855000871fbf4

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant