Skip to content

ci: disable husky in the release job so semantic-release can commit - #9

Merged
RonenMars merged 1 commit into
mainfrom
fix/release-husky-commitlint
Jul 11, 2026
Merged

ci: disable husky in the release job so semantic-release can commit#9
RonenMars merged 1 commit into
mainfrom
fix/release-husky-commitlint

Conversation

@RonenMars

@RonenMars RonenMars commented Jul 11, 2026

Copy link
Copy Markdown
Owner

Problem

The Release job has been failing on main — for PR #7 (RN engine) and PR #8 (match layout) — so nothing has published to npm: the registry is still at 1.2.0 despite two merged feat PRs that should have shipped 1.3.0.

Root cause is not npm auth.
@semantic-release/git makes a chore(release): <v> commit whose body is the generated changelog, and husky's commit-msg hook fires in CI.
commitlint then rejects the commit:

git commit -m chore(release): 1.3.0 [skip ci]
✖ footer's lines must not be longer than 100 characters [footer-max-line-length]
husky - commit-msg script failed (code 1)

Changelog lines embed GitHub commit + issue URLs, which are well over 100 chars — so effectively every release commit trips the rule, and the version bump + npm publish never run.

Fix

Set HUSKY: 0 on the Release step's env, so husky hooks are disabled for the auto-generated release commit only.
commitlint still guards human commits everywhere else (local hooks + PR title checks are untouched).

      - name: Release
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
          NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
          HUSKY: 0
        run: npx semantic-release

Effect once merged

The Release job on main succeeds and semantic-release publishes the pending 1.3.0 (the merged RN engine + match-layout work).
This PR itself is ci: scope — no bump — it just unblocks the pipeline.

The Release job runs @semantic-release/git, which makes a chore(release): <v> commit whose body is the generated changelog. Husky's commit-msg hook fires in CI and commitlint rejects it — changelog lines carry GitHub commit/issue URLs longer than the 100-char footer-max-line-length rule — so the release commit fails and no version bump or npm publish happens (npm was stuck at 1.2.0 despite two merged feat PRs).

Setting HUSKY=0 for the Release step only skips the hook on the auto-generated release commit; commitlint still guards human commits everywhere else.
@vercel

vercel Bot commented Jul 11, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated (UTC)
one-more-highlight-playground Ignored Ignored Jul 11, 2026 3:54pm

@RonenMars
RonenMars merged commit 6c1efa6 into main Jul 11, 2026
9 checks passed
@RonenMars
RonenMars deleted the fix/release-husky-commitlint branch July 11, 2026 15:58
@github-actions

Copy link
Copy Markdown

🎉 This PR is included in version 1.3.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant