Skip to content

Conversation

@BYK
Copy link
Member

@BYK BYK commented Dec 29, 2025

Summary

When running craft prepare --publish --no-git-checks, the noGitChecks flag was not being passed to the publish step, causing git checks to run even when explicitly disabled by the user.

Problem

The execPublish() function constructs a PublishOptions object but omits the required noGitChecks property. This causes:

  1. User runs: craft prepare --publish --no-git-checks 1.0.0
  2. The prepare step correctly skips git checks
  3. The publish step runs git checks anyway (because noGitChecks is undefined)

Fix

Updated execPublish() to:

  • Accept a noGitChecks parameter
  • Include it in the PublishOptions object passed to the publish handler

This ensures the user's intent to skip git checks is respected throughout the entire prepare+publish flow.

Follow up to https://github.com/getsentry/craft/pull/683/files/a1ebfffc1a0cbc40e7d96b04771672e2d6418e22#diff-adc8934db1a646fd72f3cdda4ede76ecfc3628ec0f8dd1f37403d0121183e94a

When running 'craft prepare --publish --no-git-checks', the noGitChecks
flag was not being passed to the publish step, causing git checks to run
even when explicitly disabled by the user.

This fix updates execPublish() to accept and forward the noGitChecks flag
to the PublishOptions object.
@github-actions
Copy link
Contributor

github-actions bot commented Dec 29, 2025

Semver Impact of This PR

🟢 Patch (bug fixes)

📋 Changelog Preview

This is how your changes will appear in the changelog.
Entries from this PR are highlighted with a left border (blockquote style).


This PR will not appear in the changelog.


🤖 This preview updates automatically when you update the PR.

@BYK BYK requested a review from Lms24 December 29, 2025 18:47
@BYK BYK marked this pull request as ready for review December 29, 2025 18:47
@BYK BYK enabled auto-merge (squash) December 29, 2025 18:47
@BYK BYK changed the title fix(prepare): Pass --no-git-checks flag to publish step fix(publish): Pass --no-git-checks flag to publish step Dec 29, 2025
@BYK BYK changed the title fix(publish): Pass --no-git-checks flag to publish step fix(prepare): Pass --no-git-checks flag to publish step Dec 29, 2025
@BYK BYK merged commit 8d6aaf3 into master Dec 30, 2025
18 checks passed
@BYK BYK deleted the fix/pass-no-git-checks-to-publish branch December 30, 2025 09:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants