Stirling-PDF/.github
Ludy e7631cf80c
ci(workflows): add PR comment–driven label management with authorized users (#4650)
- **What was changed**
- Added a new `handle-label-commands` job to
`.github/workflows/PR-Demo-Comment-with-react.yml` that processes PR
comments containing label commands and applies label changes to the
associated pull request.
- Introduced an authorization list `label_changer` in
`.github/config/repo_devs.json` to restrict who can manage labels via
comments.
  - Implemented parsing of comment commands in the form:
    - `add:🏷️:"Label Name"` to add a label.
    - `rm:🏷️:"Label Name"` to remove a label.
- The workflow reads `.github/labels.yml` to build a canonical map of
allowed labels (case-insensitive matching, preserves original casing).
- Only labels defined in `.github/labels.yml` can be added; removal
allows best-effort even if the label is not found in the map.
- After successful processing, the original command comment is deleted
to keep the thread clean.
- Uses the existing local action `./.github/actions/setup-bot` to
authenticate as a GitHub App for applying labels.
- Added runner hardening via `step-security/harden-runner@v2.13.1` with
egress audit mode.

- **Why the change was made**
- Streamlines triage by enabling trusted maintainers to manage labels
directly from PR comments without needing full UI interactions.
  - Ensures safety and consistency:
- Only **authorized** accounts (from `label_changer`) can execute label
commands.
- Only **known** labels (from `.github/labels.yml`) may be added,
preventing typos and drift.
  - Reduces noise by deleting comma
2025-10-29 23:31:25 +00:00
..
actions/setup-bot Standardize GitHub App Bot Authentication Across Workflows (#3582) 2025-05-27 12:36:41 +01:00
config ci(workflows): add PR comment–driven label management with authorized users (#4650) 2025-10-29 23:31:25 +00:00
ISSUE_TEMPLATE Merge branch 'decrypt' of https://github.com/Stirling-Tools/Stirling-PDF 2024-12-06 15:33:44 +00:00
scripts fix(ci): 🛡️mitigate CVE-2025-8869 by pinning pip to patched commit and upgrading dev dependency pins (#4630) 2025-10-16 22:40:14 +01:00
workflows ci(workflows): add PR comment–driven label management with authorized users (#4650) 2025-10-29 23:31:25 +00:00
CODEOWNERS Update CODEOWNERS (#4158) 2025-08-09 15:09:26 +01:00
dependabot.yml Update .pre-commit-config.yaml no. 2 2024-12-21 15:34:07 +01:00
labeler-config-srvaroa.yml chore(labeler): add new 'v2' label and expand matching rules (#4172) 2025-08-11 10:26:57 +01:00
labels.yml chore(labeler): add new 'v2' label and expand matching rules (#4172) 2025-08-11 10:26:57 +01:00
pull_request_template.md docs: restructure documentation paths, update PR template links, and add exception handling guide (#3885) 2025-07-07 09:49:44 +01:00
release.yml Add Devtools labels and update labeler configuration (#3148) 2025-03-10 08:20:04 +00:00