diff --git a/.github/maintainer/.version b/.github/maintainer/.version index cb0c939..78bc1ab 100644 --- a/.github/maintainer/.version +++ b/.github/maintainer/.version @@ -1 +1 @@ -0.5.2 +0.10.0 diff --git a/.github/workflows/maintainer.yml b/.github/workflows/maintainer.yml index 2fed486..324efec 100644 --- a/.github/workflows/maintainer.yml +++ b/.github/workflows/maintainer.yml @@ -34,7 +34,60 @@ permissions: pull-requests: write jobs: + # Short-circuit comment events that caretaker itself produced. Without this + # filter, every status / readiness / task comment caretaker writes triggers + # another caretaker run via the issue_comment webhook, producing a feedback + # loop. Comments are identified by a caretaker:* HTML-comment marker and + # by known bot logins. + dispatch-guard: + runs-on: ubuntu-latest + outputs: + should_run: ${{ steps.guard.outputs.should_run }} + steps: + - id: guard + uses: actions/github-script@v7 + with: + script: | + const ev = context.eventName; + if (ev !== "issue_comment" && ev !== "pull_request_review") { + core.setOutput("should_run", "true"); + return; + } + const payload = context.payload || {}; + if (ev === "issue_comment") { + const body = payload.comment?.body || ""; + if (/