Skip to content

feat: add assign-prs-to-author reusable workflow#4

Open
mattmillerai wants to merge 1 commit into
mainfrom
feat/assign-prs-to-author-reusable
Open

feat: add assign-prs-to-author reusable workflow#4
mattmillerai wants to merge 1 commit into
mainfrom
feat/assign-prs-to-author-reusable

Conversation

@mattmillerai
Copy link
Copy Markdown
Contributor

@mattmillerai mattmillerai commented Jun 2, 2026

What

Adds a third reusable workflow to this repo: assign-prs-to-author.yml. It assigns every open PR with no assignees to its author, so unassigned PRs get routed back to whoever opened them. Bot-authored PRs (Dependabot, Renovate, app tokens) are skipped by default via the skip-bots input.

Extracted from a copy that currently lives in Comfy-Org/cloud, following the same thin-caller pattern as cursor-review and detect-unreviewed-merge.

Why a reusable workflow

It's generic CI housekeeping with zero repo-specific anything — pure github-script over context.repo. Hosting it here means consumer repos carry a small scheduled caller instead of a maintained copy (no drift).

Permissions

Uses the caller's GITHUB_TOKEN (no secrets to pass). The calling job must grant pull-requests: write and issues: write — assignees are set through the issues API.

Caller pattern

name: Housekeeping - Assign PRs to Author
on:
  schedule:
    - cron: "0 2 * * *"   # daily at 02:00 UTC
  workflow_dispatch:
jobs:
  assign:
    permissions:
      pull-requests: write
      issues: write
    uses: Comfy-Org/github-workflows/.github/workflows/assign-prs-to-author.yml@<sha>  # v1

Extracts the housekeeping workflow that assigns every open PR with no
assignees to its author into a reusable workflow_call, so consumer repos
carry only a thin scheduled caller instead of a copy. Bot-authored PRs are
skipped by default (skip-bots input). Uses the caller's GITHUB_TOKEN, so
the calling job grants pull-requests: write + issues: write.
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