Skip to content

feat: bundle shared commitlint preset in title action - #687

Merged
neilime merged 5 commits into
mainfrom
feat/shared-commitlint-preset
Dec 3, 2026
Merged

neilime merged 5 commits into
mainfrom
feat/shared-commitlint-preset

Conversation

@neilime

@neilime neilime commented Dec 3, 2026 •

Copy link
Copy Markdown
Member

The title action should provide the shared commit policy without requiring every consumer to create a root npm project or install its application dependencies.

Bundle @hoverkraft/commitlint-config@0.0.2 in the action's existing dependency lockfile and use it as the default. Repository configs can extend it by name through the action's existing module-resolution setup. Repository overrides remain authoritative; malformed configs and missing presets still fail.

This revision removes the duplicated dependency detection and installation from both reusable workflows, the new root manifest and lockfile, the Makefile bootstrap, and the extra Dependabot entry. The linter workflow is unchanged. Nx consumers keep @commitlint/config-nx-scopes and install their workspace dependencies before calling the standalone title action.

The companion linter-image change, hoverkraft-tech/docker-base-images#306, bundles the same preset at build time. Until that image is released, this repository keeps its existing commitlint rules and image pin. Consumer rollout requires that release; this PR does not introduce an unreleased image reference or migrate CI reporting.

Validation:

  • Clean installation from the action's lockfile and all 25 title-action tests pass (about 1.5 seconds).
  • Coverage includes shared warnings for humans and bots, invalid types and empty subjects, bundled preset resolution without consumer dependencies, and blocking repository severity overrides.
  • Biome, Prettier, Actionlint and git diff --check pass for the changed files.
  • Action/workflow documentation regenerated through the existing CI Dokumentor generator.

Merge remains with the repository owner.

@github-actions github-actions Bot added the type: feature Introduces a new feature label Dec 3, 2026
@github-actions

github-actions Bot commented Dec 3, 2026 •

Copy link
Copy Markdown
Contributor

Internal - Pull request - Continuous Integration - Test results

Workflow run and full reports · Commit 22493ff

Jobs: 8 success · 0 failure · 0 cancelled · 0 skipped · 0 abandoned.

Test: 322 passed · 0 failed · 0 skipped.

Test details

Test results

Test Results

Status Count
✅ Passed 322
❌ Failed 0
⏭️ Skipped 0
Total 322
Suite Passed Failed Skipped
AstroCheckParser 5 0 0
CheckStyleParser 4 0 0
Cobertura auto-detection 2 0 0
CoberturaParser 3 0 0
Compact category comments 2 0 0
Consolidated reports 2 0 0
Coverage 2 0 0
ESLintParser 3 0 0
JUnitParser 5 0 0
LCOVParser 3 0 0
LintIssue 2 0 0
LoggerService 1 0 0
MarkdownFormatter 2 0 0
Nested JUnit suites 2 0 0
ParserFactory 5 0 0
PathRewriter 14 0 0
PrettierParser 4 0 0
Report exclusions 1 0 0
ReportData 4 0 0
ReportParserCore 2 0 0
ReportParserCore.parseOutputFormats 2 0 0
ReportPathResolver 6 0 0
run 10 0 0
SarifParser 4 0 0
SummaryFormatter 2 0 0
TAPParser 6 0 0
TestResult 4 0 0
Unknown Suite 220 0 0

✅ Pass Rate: 100.0%

Job results and report availability
Job Result Report artifacts
lint success 2
test-action-distributions success 1
test-action-test-action-distribution success 1
test-action-lint-pull-request-title success 1
test-action-create-and-merge-pull-request success 1
test-action-parse-ci-reports success 1
test-action-need-fix-to-issue success 1
test-action-download-artifact success 1

Only this attempt is included. On partial reruns, rerun all producer jobs for complete reports. CodeQL findings remain in code scanning; other diagnostics remain in the job logs.

@github-actions

github-actions Bot commented Dec 3, 2026 •

Copy link
Copy Markdown
Contributor

Internal - Pull request - Continuous Integration - Code coverage

Workflow run and full reports · Commit 22493ff

Jobs: 8 success · 0 failure · 0 cancelled · 0 skipped · 0 abandoned.

Coverage: 7 source report(s); percentages remain separate.

Coverage details

Coverage results

ci-reports-1-test-action-create-and-merge-pull-request-actions-create-and-merge-pull-request-da1611f5-17db-4689-8ca9-f69eec7fba3c/lcov.info

Coverage

Metric Covered Total Percentage
Lines 205 205 100.00%
Branches 60 62 96.77%
Functions 26 30 86.67%

Overall: 100.00% 🟢
🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩

ci-reports-1-test-action-distributions-actions-action-distributions-1c1671cc-4948-46b2-b6e3-36d81bb03b64/lcov.info

Coverage

Metric Covered Total Percentage
Lines 898 917 97.93%
Branches 253 262 96.56%
Functions 79 80 98.75%

Overall: 97.93% 🟢
🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩

ci-reports-1-test-action-download-artifact-actions-download-artifact-6655f921-386a-4bb6-b61c-ee8a88d2c066/lcov.info

Coverage

Metric Covered Total Percentage
Lines 147 147 100.00%
Branches 50 54 92.59%
Functions 7 7 100.00%

Overall: 100.00% 🟢
🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩

ci-reports-1-test-action-lint-pull-request-title-actions-quality-lint-pull-request-title-17795496-52fc-4027-a220-9856e229e6cb/lcov.info

Coverage

Metric Covered Total Percentage
Lines 45 45 100.00%
Branches 14 15 93.33%
Functions 1 1 100.00%

Overall: 100.00% 🟢
🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩

ci-reports-1-test-action-need-fix-to-issue-actions-need-fix-to-issue-38774ff6-c9c3-4a74-ac1a-419e4a658725/lcov.info

Coverage

Metric Covered Total Percentage
Lines 95 95 100.00%
Branches 36 36 100.00%
Functions 7 7 100.00%

Overall: 100.00% 🟢
🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩

ci-reports-1-test-action-parse-ci-reports-actions-quality-parse-ci-reports-082f4c5a-1894-4eb5-b70a-d3156d71de34/lcov.info

Coverage

Metric Covered Total Percentage
Lines 2563 2687 95.39%
Branches 478 578 82.70%
Functions 194 200 97.00%

Overall: 95.39% 🟢
🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩⬜

ci-reports-1-test-action-test-action-distribution-actions-quality-test-action-distribution-2df074c2-8e5b-4c41-b57e-70ddf7ee0359/lcov.info

Coverage

Metric Covered Total Percentage
Lines 71 71 100.00%
Branches 13 13 100.00%
Functions 4 4 100.00%

Overall: 100.00% 🟢
🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩

Job results and report availability
Job Result Report artifacts
lint success 2
test-action-distributions success 1
test-action-test-action-distribution success 1
test-action-lint-pull-request-title success 1
test-action-create-and-merge-pull-request success 1
test-action-parse-ci-reports success 1
test-action-need-fix-to-issue success 1
test-action-download-artifact success 1

Only this attempt is included. On partial reruns, rerun all producer jobs for complete reports. CodeQL findings remain in code scanning; other diagnostics remain in the job logs.

@github-actions

github-actions Bot commented Dec 3, 2026 •

Copy link
Copy Markdown
Contributor

Internal - Pull request - Continuous Integration - Lint results

Workflow run and full reports · Commit 22493ff

Jobs: 8 success · 0 failure · 0 cancelled · 0 skipped · 0 abandoned.

Lint: Collected diagnostics and Super-Linter summaries. Execution status is included in the job outcomes.

Super-Linter details

Super-linter summary

Language Validation result
BIOME_FORMAT Pass ✅
BIOME_LINT Pass ✅
CHECKOV Pass ✅
GITHUB_ACTIONS Pass ✅
GITHUB_ACTIONS_ZIZMOR Pass ✅
GITLEAKS Pass ✅
GIT_COMMITLINT Pass ✅
GIT_MERGE_CONFLICT_MARKERS Pass ✅
JSCPD Pass ✅
MARKDOWN Pass ✅
MARKDOWN_PRETTIER Pass ✅
NATURAL_LANGUAGE Pass ✅
PRE_COMMIT Pass ✅
SPELL_CODESPELL Pass ✅
TRIVY Pass ✅
YAML Pass ✅
YAML_PRETTIER Pass ✅

All files and directories linted successfully

For more information, see the GitHub Actions workflow run

Powered by Super-linter
Super-linter revision: 2da136927bd4a73596db63044b504547c62cb854
Super-linter version: 9.0.0

Super-Linter details
Linter Status
Fixture linter ✅
Job results and report availability
Job Result Report artifacts
lint success 2
test-action-distributions success 1
test-action-test-action-distribution success 1
test-action-lint-pull-request-title success 1
test-action-create-and-merge-pull-request success 1
test-action-parse-ci-reports success 1
test-action-need-fix-to-issue success 1
test-action-download-artifact success 1

Only this attempt is included. On partial reruns, rerun all producer jobs for complete reports. CodeQL findings remain in code scanning; other diagnostics remain in the job logs.

@neilime neilime changed the title feat: add a shared commitlint preset feat: install shared commitlint preset in lint workflows Dec 3, 2026
neilime added a commit to hoverkraft-tech/commitlint-config that referenced this pull request Dec 3, 2026
Repositories currently duplicate their commitlint policy, and blocking
casing or length rules reject valid generated dependency updates. Add
`@hoverkraft/commitlint-config` as one independently versioned public
package.

The preset extends the conventional configuration. Subject casing and
header, body and footer lengths produce warnings for all authors.
Existing conventional errors and explicit repository overrides stay
blocking. Dependabot uses explicit `build` prefixes and dependency
scopes; there are no bot exemptions or message rewrites.

Package delivery follows
[docusaurus-theme](https://github.com/hoverkraft-tech/docusaurus-theme):
shared workflows prepare the version and tag, run CI against that
source, validate an isolated consumer, and publish the exact validated
tarball through npm OIDC with provenance. This single JSON package needs
no build or workspace. Usage, contributor, release and decision guides
are included.

The development environment follows Hoverkraft conventions: Debian, Zsh,
Node.js 24, Docker-in-Docker, GitHub CLI with `gh act`, a generated
feature lockfile, and automatic locked dependency installation.
Dependabot maintains the devcontainer features. The supplied artwork is
included as a README logo and a self-contained social preview SVG, with
a matching 1280 by 640 PNG for GitHub upload.

Workflow consumption is handled separately by
hoverkraft-tech/ci-github-common#687.

Validation:
- Built and started the devcontainer with the frozen feature lockfile;
verified the non-root user, Node.js 24, GitHub CLI, `gh act`, Docker and
all 12 policy tests (43.2 seconds including setup). The temporary
container and volumes were removed.
- SVGs rendered and inspected; the 30,934-byte PNG matches the final SVG
exactly and meets GitHub dimensions. Full repository lint and
documentation link checks passed.
- 12 policy tests passed, including warnings alongside blocking errors
and stricter repository overrides (about 0.44 seconds).
- Packed tarball installed in an isolated commitlint consumer; consumer
validation and npm publication dry run passed (3 seconds). This
exercises package exports and dependency resolution without repeating
the policy matrix.
- Full repository Super-Linter checks passed; documentation links and
whitespace checked.

Before the first release, an npm package maintainer must establish
package ownership and configure the trusted publisher for
`hoverkraft-tech/commitlint-config`, workflow `release.yml`. The
organization release App, variable and secrets already cover all
repositories. This PR does not publish an npm version.
@github-actions

github-actions Bot commented Dec 3, 2026 •

Copy link
Copy Markdown
Contributor

CI report

Workflow run and full summary · Commit 39016e2

Lint

Passed checks: 1

Successful lint checks (1)
Check Project Context Result Findings
Super-Linter . - ✅ Passed Native report

Tests

246 passed · 0 failed · 0 skipped

Successful test checks (9)
Check Project Context Result Passed Failed Skipped
Node.js action checks actions/action-distributions - ✅ Passed 149 0 0
Node.js action checks actions/create-and-merge-pull-request - ✅ Passed 17 0 0
Node.js action checks actions/download-artifact - ✅ Passed 7 0 0
Node.js action checks actions/need-fix-to-issue - ✅ Passed 9 0 0
Node.js action checks actions/quality/discard-report-fixtures - ✅ Passed 1 0 0
Node.js action checks actions/quality/lint-pull-request-title - ✅ Passed 25 0 0
Node.js action checks actions/quality/prepare-ci-reports - ✅ Passed 9 0 0
Node.js action checks actions/quality/publish-ci-reports - ✅ Passed 25 0 0
Node.js action checks actions/quality/test-action-distribution - ✅ Passed 4 0 0

Totals count test executions, including runtime variants.

Test coverage

94.6% lines · 90.1% branches

2739 / 2893 lines covered; 704 / 781 branches covered.

Source: merged producer reports, calculated by ReportGenerator.

Coverage by project and context
Check Project Context Lines
Node.js action checks actions/action-distributions - 97.9%
Node.js action checks actions/create-and-merge-pull-request - 100%
Node.js action checks actions/download-artifact - 98.6%
Node.js action checks actions/need-fix-to-issue - 100%
Node.js action checks actions/quality/discard-report-fixtures - 100%
Node.js action checks actions/quality/lint-pull-request-title - 100%
Node.js action checks actions/quality/prepare-ci-reports - 88.2%
Node.js action checks actions/quality/publish-ci-reports - 91.3%
Node.js action checks actions/quality/test-action-distribution - 100%

Project measurements are shown separately. The total above merges covered source lines; it does not average percentages.

Workflow jobs
Job Result
security success
test-bundled-actions success
test-action-distributions success
test-action-test-action-distribution success
lint success
test-action-matrix-outputs success
test-action-create-and-merge-pull-request success
test-action-lint-pull-request-title success
test-action-checkout success
test-action-checkout-issue-comment success
test-action-get-github-actions-bot-user success
test-action-get-issue-number success
test-action-need-fix-to-issue success
test-action-repository-owner-is-organization success
test-action-slugify success
test-action-download-artifact success
test-action-working-directory success
test-action-publish-ci-reports success
test-action-discard-report-fixtures success
test-workflow-check-jobs success
test-action-prepare-ci-reports success

The required CI complete check determines whether this workflow passed. Jobs without structured reports remain available in the workflow run.

@neilime neilime changed the title feat: install shared commitlint preset in lint workflows feat: bundle shared commitlint preset in title action Dec 3, 2026
@neilime
neilime force-pushed the feat/shared-commitlint-preset branch from c225a1f to 39016e2 Compare December 3, 2026 18:23
@neilime
neilime merged commit 26f3d68 into main Dec 3, 2026
193 checks passed
@neilime
neilime deleted the feat/shared-commitlint-preset branch December 3, 2026 18:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

type: feature Introduces a new feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant