Skip to content

feat: add Claude Code post-edit lint hook#1917

Merged
KRRT7 merged 3 commits intomainfrom
cf-claude-code-hooks
Mar 27, 2026
Merged

feat: add Claude Code post-edit lint hook#1917
KRRT7 merged 3 commits intomainfrom
cf-claude-code-hooks

Conversation

@KRRT7
Copy link
Copy Markdown
Collaborator

@KRRT7 KRRT7 commented Mar 27, 2026

Summary

  • Adds a PostToolUse hook that runs uv run prek on Python files after Edit/Write, auto-fixing lint and formatting issues at edit time
  • Unignores .claude/settings.json and .claude/hooks/ in .gitignore so hooks are shared with the team
  • Bumps ruff-pre-commit to v0.15.8

Test plan

  • Verified hook triggers on Edit/Write and auto-removes unused imports
  • Verified hook is skipped for non-Python files

KRRT7 added 2 commits March 27, 2026 08:25
Automatically runs `uv run prek` on Python files after Edit/Write
tool usage to catch lint and formatting issues at edit time.
@claude
Copy link
Copy Markdown
Contributor

claude bot commented Mar 27, 2026

Claude finished @KRRT7's task in 1m 5s —— View job


No substantive code changes to review.

All changed files are config/docs/tooling (.claude/ rules and hooks, settings.json, .gitignore, .pre-commit-config.yaml, CLAUDE.md, uv.lock). No production source files were modified.

Move pre-commit/pre-push prek rules from code-style.md to git.md,
deduplicate pipeline docs in CLAUDE.md, and add shared workflow rules.
@KRRT7 KRRT7 merged commit 2c4989c into main Mar 27, 2026
25 of 27 checks passed
@KRRT7 KRRT7 deleted the cf-claude-code-hooks branch March 27, 2026 14:56
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.

1 participant