litestar-org / litestar-org/project-template

ci: add PR auto-labeler

Open
#43 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

ci github_actions
Dominant language
Python
Stars
13
Forks
3
PR merge metrics
No merged PRs in 30d

Description

## Context

Adopt PR auto-labeling (from litestar-org/project-template#16) using `fuxingloh/multi-labeler` driven by a `.github/labeler.yml` config, plus a job that tags PRs internal/external.

> This is the **adapt-heavy** item: PR #16's 306-line `labeler.yml` is tailored to the litestar monorepo (`test/unit`, `test/e2e`, `v3` base branch, …) and the internal/external job uses a **hardcoded maintainer list**. Both need generalizing for a template.

## Proposed tasks

- [ ] Add `.github/workflows/pr-labeler.yml` (SHA-pinned, least-privilege) + `.github/labeler.yml`
- [ ] Write a **template-appropriate** `labeler.yml`:
- `type/*` from Conventional Commit title prefixes (feat/fix/docs/…)
- `area/*` from generic paths (`src/**`, `tests/**`, `docs/**`, `.github/**`)
- `Breaking` from `!` in the title
- [ ] Create the labels the config references (they don't exist in this repo yet)
- [ ] Decide the internal/external approach: replace the hardcoded maintainer list with org-team membership (e.g. `@litestar-org/members`) or drop that job
- [ ] Ensure it passes the zizmor gate (#22/#39)

## Notes

- Safe use of `pull_request_target`: label-only actions, no checkout/execution of PR head code.
- Pairs with #22's existing repo labels and the CODEOWNERS teams from #26.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by comparing the 306-line labeler.yml and workflow from litestar-org/project-template#16 with this repository’s labels from #22 and CODEOWNERS teams from #26. Define the template-appropriate paths, title rules, and internal/external decision, then add .github/workflows/pr-labeler.yml and .github/labeler.yml. Done means referenced labels exist and the setup passes the zizmor gate from #22/#39.

Written by the indexing model from the issue text.

Assessment

Tech stack
github-actions, yaml
Domain
ci-cd, devops
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.