Skip to content

feat: Set up pre-commit hooks with AsciiDoc linter#90

Merged
raifdmueller merged 1 commit intoLLM-Coding:mainfrom
raifdmueller:main
Feb 13, 2026
Merged

feat: Set up pre-commit hooks with AsciiDoc linter#90
raifdmueller merged 1 commit intoLLM-Coding:mainfrom
raifdmueller:main

Conversation

@raifdmueller
Copy link
Contributor

Changes

Implements Issue #82: Pre-commit hooks with AsciiDoc linter

What's New

Pre-commit configuration (.pre-commit-config.yaml)

  • AsciiDoc linter runs automatically on all .adoc files
  • Standard hooks: trailing whitespace, EOF fixer, YAML/JSON validation
  • Runs on git commit, validates before code is committed

Installation script (.pre-commit-install.sh)

  • One-command setup: ./pre-commit-install.sh
  • Installs pre-commit framework
  • Installs AsciiDoc linter
  • Sets up git hooks

Updated CONTRIBUTING.adoc

  • Added developer setup section
  • Pre-commit hooks now required for all contributors
  • Instructions for manual hook execution

Benefits

  • Prevents invalid AsciiDoc from being committed
  • Consistency: Same linter rules in CI and locally
  • Fast feedback: Catch errors before push
  • Easy setup: Single script installation

How Contributors Use It

# First time setup
./pre-commit-install.sh

# Hooks run automatically on commit
git commit -m "feat: Add new anchor"

# Manual execution
pre-commit run --all-files

CI Integration

Pre-commit hooks complement the existing CI workflow:

  • Local: Pre-commit catches issues before commit
  • CI: GitHub Actions validates on PR (fallback)

Closes #82

- Add .pre-commit-config.yaml with AsciiDoc linter hook
- Add .pre-commit-install.sh installation script
- Update CONTRIBUTING.adoc with developer setup section
- Hooks run automatically on git commit
- Validates all .adoc files before commit

Closes LLM-Coding#82
@raifdmueller raifdmueller merged commit 1783811 into LLM-Coding:main Feb 13, 2026
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.

Tier 1: Set up Pre-Commit Hooks (husky + lint-staged)

1 participant