Skip to content

Label draft PRs with "🚧 Draft/WIP" - #13

Open
OsirisTerje wants to merge 1 commit into
mainfrom
draft-label
Open

OsirisTerje wants to merge 1 commit into
mainfrom
draft-label

Conversation

@OsirisTerje

Copy link
Copy Markdown
Member

Adds .github/workflows/draft-label.yml, which calls the shared workflow in nunit/.github to keep the 🚧 Draft/WIP label in sync with the PR's draft state:

  • Adds the label when a PR is opened as a draft or converted to draft.
  • Removes it when the PR is marked ready for review.

It runs on pull_request_target, so PRs from forks get a token that can write labels. No PR code is checked out or run.

Depends on nunit/.github#3. Merge that first, or this workflow fails because the shared workflow is not on main yet.

The label already exists in this repo.

🤖 Made by @OsirisTerje with Claude

Calls the reusable draft-label workflow in nunit/.github.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Copilot AI balanced review requested due to automatic review settings October 24, 2026 14:30

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔵 Needs a closer look

The prerequisite nunit/.github#3 is still unmerged, so the shared workflow must become available on main before this PR is merged.

No open issues 🎉

What changed in this PR

Adds a caller workflow to keep the 🚧 Draft/WIP label synchronized with pull request draft status through the shared NUnit workflow.

Changes:

  • Runs when PRs are opened, converted to draft, or marked ready for review.
  • Uses pull_request_target with label-writing permissions to support fork PRs.
  • Delegates labeling to nunit/.github without checking out or running PR code.
File Description
.github/​workflows/​draft-label.yml Adds event triggers, permissions, and the shared workflow call.

Review effort: Balanced

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants