Median Task: BNN-8
Build a module that parses CONTRIBUTING.md files and enforces their clauses against incoming pull requests and contributions.
Core requirements:
Markdown Parser
- Parse CONTRIBUTING.md into discrete, named sub-rules extracted from headings, list items, and block content
- Handle nested clauses, ordered and unordered lists, and mixed formatting gracefully
- Preserve original wording for display while generating a normalized rule identifier per clause
- Parser must be robust and handle real-world CONTRIBUTING.md variations across popular repos
Rule Configuration UI
- Display parsed clauses as individually toggleable rules in a clean UI
- Allow users to mark rules as critical (top-tier) vs standard
- Per-rule action config: warn, request changes, close PR, add label, post comment, or do nothing
- Support rule groupings so users can define thresholds like close PR if any 2 critical rules are violated
- Visual indicator on each rule showing its current enforcement action
- Allow reordering and manual priority ranking of rules via drag and drop
Enforcement Engine
- Evaluate incoming PRs against configured rules using a combination of checklist detection in PR body, commit message scanning, and optionally linked issue validation
- Support threshold-based logic: eg close immediately if top 3 critical rules are not met, or soft-close if any standard rule is missing
- Trigger configurable actions per violation: auto-close, label, comment with specific rule failures listed, or queue for human review
- Store rule snapshots so enforcement stays consistent even if CONTRIBUTING.md changes mid-cycle
Sync and Versioning
- Detect changes to CONTRIBUTING.md in the repo and prompt the user to re-map or update their rule config
- Show a diff of added or removed clauses when the file changes
This module should feel native to Tripwire and follow existing module conventions for config storage, webhook handling, and UI patterns.
Median Task: BNN-8
Build a module that parses CONTRIBUTING.md files and enforces their clauses against incoming pull requests and contributions.
Core requirements:
Markdown Parser
Rule Configuration UI
Enforcement Engine
Sync and Versioning
This module should feel native to Tripwire and follow existing module conventions for config storage, webhook handling, and UI patterns.