fix: protected branch detection and non-blocking hooks

- Add protected branch detection to /commit command (Step 1)
- Warn users before committing to protected branches
- Offer to create feature branch automatically
- Rewrite doc-guardian hook to be truly non-blocking
- Enforce strict [plugin-name] prefix in all hook outputs
- Add forbidden words list to prevent accidental blocking

Fixes #109, #110

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
2026-01-23 11:05:12 -05:00
parent 1f55387e9e
commit 35cf20e02d
7 changed files with 68 additions and 10 deletions

View File

@@ -4,6 +4,32 @@ All notable changes to the Leo Claude Marketplace will be documented in this fil
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
## [3.1.2] - 2026-01-23
### Added
- **git-flow:** `/commit` now detects protected branches before committing
- Warns when on protected branch (main, master, development, staging, production)
- Offers to create feature branch automatically instead of committing directly
- Configurable via `GIT_PROTECTED_BRANCHES` environment variable
- Resolves issue where commits to protected branches would fail on push
### Changed
- **doc-guardian:** Hook completely rewritten to be truly non-blocking
- Removed all analysis logic that could trigger workflow stoppage
- Now outputs only minimal notification for config file changes
- Forbidden words list prevents accidental blocking output
- **All hooks:** Stricter plugin prefix enforcement
- All prompts now mandate `[plugin-name]` prefix with "NO EXCEPTIONS" rule
- Simplified output formats with word limits
- Consistent structure across projman, pr-review, code-sentinel, doc-guardian
### Fixed
- Protected branch workflow: Claude no longer commits directly to protected branches and then fails on push (fixes #109)
- doc-guardian hook no longer blocks workflow with drift analysis (fixes #110)
- Hook messages now consistently show plugin name prefix (fixes #110)
---
## [3.1.1] - 2026-01-22
### Added