From 8a537a7a1dfc9aef350b4ac6d8ef5f3a6fd09006 Mon Sep 17 00:00:00 2001 From: Maxwell Date: Mon, 20 Jul 2026 12:25:18 +0200 Subject: [PATCH] docs(project): add branch-selection table and dependencies type for agent workflows - release-drafter-config.yml: document autolabeler branch-to-label mapping - CONTRIBUTING.md: add `dependencies` branch type, tighten `build` description - AGENTS.md: add branch prefix decision table for agentic workflows --- .github/release-drafter-config.yml | 5 +++++ AGENTS.md | 22 +++++++++++++++++++++- CONTRIBUTING.md | 3 ++- 3 files changed, 28 insertions(+), 2 deletions(-) diff --git a/.github/release-drafter-config.yml b/.github/release-drafter-config.yml index 6b76a91..f78bc2c 100644 --- a/.github/release-drafter-config.yml +++ b/.github/release-drafter-config.yml @@ -37,6 +37,11 @@ categories: labels: - ':rewind: revert' collapse-after: 5 +# ── Autolabeler ─────────────────────────────────────────────── +# When a PR is opened from a branch matching the regex below, +# Release Drafter auto-applies the corresponding label. +# This ensures branch naming drives changelog categorization. +# Keep these in sync with CONTRIBUTING.md branch types. autolabeler: - label: ':star2: feature' branch: diff --git a/AGENTS.md b/AGENTS.md index a3926fc..7a8ca15 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -99,9 +99,29 @@ See `CONTRIBUTING.md` for full details. Quick reference: - **Branch**: `/-` (e.g., `feat/1208-implement-override-merging`) - **Commit**: `(): ` (e.g., `feat(config): add profile overlay discovery`) - **PR title**: same format as commits, linked to the relevant issue -- **Valid types**: `feat`, `fix`, `chore`, `docs`, `refactor`, `test`, `build`, `ci`, `revert` +- **Valid types**: `feat`, `fix`, `dependencies`, `chore`, `docs`, `refactor`, `test`, `build`, `ci`, `revert` - **Valid scopes**: `config`, `generate`, `render`, `cli`, `docker`, `secrets`, `project`, `env`, `compose`, `process` +### Branch prefix selection for agents + +When creating a branch automatically, select the prefix based on the change intent. +The release drafter autolabeler maps each branch prefix to a changelog label: + +| What you are doing | Branch prefix | Auto-label applied | +|---|---|---| +| Adding a new feature or capability | `feat` | `:star2: feature` | +| Fixing a bug | `fix` | `:adhesive_bandage: bug fix` | +| Updating dependencies (Renovate, manual) | `dependencies` | `:dagger: dependencies` | +| Changing build system or tooling | `build` | `:dagger: dependencies` | +| Routine maintenance, chores | `chore` | `:wrench: enhancement` | +| Documentation only | `docs` | `:books: docs` | +| Refactoring without behavior change | `refactor` | `:hammer_and_wrench: refactor` | +| Adding or fixing tests | `test` | `:test_tube: testing` | +| CI/CD configuration | `ci` | `:construction_worker: ci` | +| Reverting a previous change | `revert` | `:rewind: revert` | + +If no issue number exists, use `/` and link to an issue once created. + ## Documentation requirements - `AGENTS.md` (this file) and `docs/` must be kept up to date with code changes. If you add, remove, or change behavior, update them in the same PR. diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 01fbffe..cf7bbd5 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -39,7 +39,8 @@ Supported types: - `docs` -- Documentation only changes - `refactor` -- Code change that neither fixes a bug nor adds a feature - `test` -- Adding missing or correcting existing tests -- `build` -- Changes that affect the build system or dependencies +- `build` -- Changes that affect the build system or tooling +- `dependencies` -- Updating external dependencies (distinct from build-system changes) - `ci` -- Changes to CI configuration or automation scripts - `revert` -- Reverting a previous commit