Skip to content

feat: add .pre-commit-config.yaml mirroring CI checks#78

Merged
CybotTM merged 1 commit into
mainfrom
feat/precommit-config
May 23, 2026
Merged

feat: add .pre-commit-config.yaml mirroring CI checks#78
CybotTM merged 1 commit into
mainfrom
feat/precommit-config

Conversation

@CybotTM
Copy link
Copy Markdown
Member

@CybotTM CybotTM commented May 23, 2026

Summary

Wires netresearch/skill-repo-skill@v1.22.0 as a pre-commit hook provider so validate-skill, check-version-parity, plus markdownlint-cli2 / yamllint / actionlint / ruff / shellcheck run locally before commit.

Part of the fleet rollout following the CI/Hook Parity Principle in netresearch/agent-harness-skill#27. Pilot phase (skill-repo-skill#109, go-development-skill#34, security-audit-skill#71, php-modernization-skill#57) validated the template across with/without yamllint and with/without package.json configurations.

Files

  • .pre-commit-config.yaml — standard NR skill-repo hook set (pre-commit-hooks meta, validate-skill, check-version-parity, markdownlint-cli2, yamllint, actionlint, ruff, shellcheck)

Wires netresearch/skill-repo-skill@v1.22.0 as a pre-commit hook
provider so validate-skill, check-version-parity, and the standard
linter set (markdownlint-cli2, yamllint, actionlint, ruff, shellcheck)
run locally before commit instead of only in CI.
- package.json scripts.prepare: invokes pre-commit install --install-hooks
  if pre-commit is on PATH; silent no-op otherwise. Auto-activates hooks
  on `npm install`.

Part of the fleet rollout following netresearch/agent-harness-skill#27
(CI/Hook Parity Principle) and skill-repo-skill v1.22.0 (hook exposure).

Signed-off-by: Sebastian Mendel <info@sebastianmendel.de>
Copilot AI review requested due to automatic review settings May 23, 2026 05:56
@sonarqubecloud
Copy link
Copy Markdown

@github-actions
Copy link
Copy Markdown
Contributor

Dependency Review

✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.

Scanned Files

None

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds local pre-commit tooling to mirror CI validation for this skill repository and auto-installs hooks when possible during npm setup.

Changes:

  • Adds .pre-commit-config.yaml with validation, linting, formatting, and shell checks pinned to specific hook versions.
  • Adds an npm prepare script intended to install pre-commit hooks automatically when pre-commit is available.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
.pre-commit-config.yaml Defines the local pre-commit hook set matching CI validation/lint checks.
package.json Adds a lifecycle script to install pre-commit hooks during npm setup.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread package.json
Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces a .pre-commit-config.yaml file and a prepare script in package.json to automate hook installation. Feedback highlights that several specified hook versions are non-existent and will cause failures. Additionally, the yamllint hook references a missing configuration file, and it is suggested to remove the --install-hooks flag from the package.json script to improve developer experience by avoiding slow installation times.

Comment thread .pre-commit-config.yaml
Comment thread .pre-commit-config.yaml
Comment thread .pre-commit-config.yaml
Comment thread .pre-commit-config.yaml
Comment thread .pre-commit-config.yaml
Comment thread .pre-commit-config.yaml
Comment thread package.json
@CybotTM CybotTM merged commit 3b07c5c into main May 23, 2026
21 of 22 checks passed
@CybotTM CybotTM deleted the feat/precommit-config branch May 23, 2026 06:20
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.

2 participants