Skip to content

feat(ci): add PR lint gate, issue automation, and monorepo governance workflows #87

@kongche-jbw

Description

@kongche-jbw

Summary

This issue tracks the addition of GitHub Actions workflows and repository
governance configuration to standardize the contribution process and issue
lifecycle across all ANOLISA sub-projects.

Motivation

Currently the project has no automated tooling for:

  1. Enforcing commit message format, PR title format, branch naming, and issue
    linking consistency in pull requests
  2. Automatically routing new issues to the responsible maintainer and sending
    notifications
  3. Notifying the team when a PR is merged into main
  4. Defining code ownership for automatic review routing

Proposed Changes

1. prelint.yml — PR lint gate

Runs on every PR targeting main. Three checks in a single job:

Step Checks
Commit Message Lint Conventional Commits format via commitlint.config.json
PR Title Validation type(scope): description pattern + valid scopes
Branch Name Validation feat/fix/chore/docs/refactor/ci/deps/<scope>/<desc> patterns
Linked Issue Check PR body must contain closes/fixes/resolves #N or no-issue: <reason>

2. issue-automation.yml — Issue auto-labeling

Triggered when a new issue is opened. Parses the Issue Form Component
dropdown and applies the corresponding component:xxx label. Skips silently
if a component label already exists (prevents double-trigger).

3. issue-triage.yml — Issue routing and notification

Triggered when a component:xxx label is added. Reads .github/maintainers.json
via GitHub API (no checkout required), assigns the relevant maintainer(s), posts
a triage comment, and sends DingTalk + email notifications.

4. pr-merged.yml — PR merge notification

Triggered when a PR is merged into main. Sends a DingTalk notification
with PR title, author, and source branch via HMAC-SHA256 signed webhook.

5. CODEOWNERS — Code review routing

Maps sub-project directories to their owners for automatic review requests.
Works with Branch Protection "Require review from Code Owners".

6. Supporting configuration

  • .github/maintainers.json — maintainer → component mapping for issue routing
  • .github/pull_request_template.md — pre-filled closes # to enforce issue linking
  • .github/ISSUE_TEMPLATE/ — four templates: bug / feature / question / config
  • .github/dependabot.yml — weekly dependency updates for npm, cargo (×2), and Actions
  • .github/commitlint.config.json — commit scope enforcement

Scope

  • Multiple / Project-wide (CI infrastructure)

Metadata

Metadata

Assignees

Labels

scope:ci.github/ ci scripts

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions