docs(git): remove stale check-manifests/skill-frontmatter examples
f11b645andbde9f7fswept check-manifests and skill-frontmatter references left over frome647f14andc8a7c9e, but missed two worked examples in this vendored pre-commit research doc: a "Validate a generated file" hook naming the deleted scripts/check-manifests.sh, and a "SKILL.md frontmatter validation (inline bash, as used in this repo)" example for the skill-frontmatter hook, folded into skill-size-check.sh inc8a7c9e. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01YR2CjVumUbEGWcMikcoXBD
This commit is contained in:
@@ -157,20 +157,6 @@ pre-commit run --from-ref origin/main --to-ref HEAD
|
|||||||
files: \.env(\..+)?$
|
files: \.env(\..+)?$
|
||||||
```
|
```
|
||||||
|
|
||||||
### Validate a generated file
|
|
||||||
|
|
||||||
```yaml
|
|
||||||
- repo: local
|
|
||||||
hooks:
|
|
||||||
- id: validate-manifest
|
|
||||||
name: Validate plugin manifest
|
|
||||||
entry: bash scripts/check-manifests.sh
|
|
||||||
language: unsupported_script
|
|
||||||
files: ^\.claude-plugin/
|
|
||||||
pass_filenames: false
|
|
||||||
always_run: false
|
|
||||||
```
|
|
||||||
|
|
||||||
### Run full test suite pre-push
|
### Run full test suite pre-push
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
@@ -185,29 +171,6 @@ pre-commit run --from-ref origin/main --to-ref HEAD
|
|||||||
stages: [pre-push]
|
stages: [pre-push]
|
||||||
```
|
```
|
||||||
|
|
||||||
### Validate SKILL.md frontmatter (inline bash, as used in this repo)
|
|
||||||
|
|
||||||
```yaml
|
|
||||||
- repo: local
|
|
||||||
hooks:
|
|
||||||
- id: skill-frontmatter
|
|
||||||
name: SKILL.md frontmatter validation
|
|
||||||
entry: bash
|
|
||||||
language: system
|
|
||||||
files: 'SKILL\.md$'
|
|
||||||
args:
|
|
||||||
- -c
|
|
||||||
- |
|
|
||||||
for f in "$@"; do
|
|
||||||
if [[ -f "$f" ]]; then
|
|
||||||
if ! grep -q "^name:" "$f" || ! grep -q "^description:" "$f"; then
|
|
||||||
echo "ERROR: $f missing required frontmatter (name: and description:)"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
```
|
|
||||||
|
|
||||||
## Adding meta-validation
|
## Adding meta-validation
|
||||||
|
|
||||||
Add after all other repos to catch dead hooks/excludes:
|
Add after all other repos to catch dead hooks/excludes:
|
||||||
|
|||||||
Reference in New Issue
Block a user