From cf6e4d0ed743f55c554e2d885a3c426c34f063b5 Mon Sep 17 00:00:00 2001 From: Vincent Koc Date: Wed, 29 Apr 2026 01:34:23 -0700 Subject: [PATCH] ci: keep clownfish command reactions owned --- .github/workflows/maintainer-command-reactions.yml | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/.github/workflows/maintainer-command-reactions.yml b/.github/workflows/maintainer-command-reactions.yml index 2970777a6a5..b45224b342b 100644 --- a/.github/workflows/maintainer-command-reactions.yml +++ b/.github/workflows/maintainer-command-reactions.yml @@ -61,6 +61,10 @@ jobs: commandLine.startsWith("/autoclose ") || commandLine === "/clownfish autoclose" || commandLine.startsWith("/clownfish autoclose "); + const isClownfishCommand = + isAutocloseCommand || + commandLine === "/clownfish automerge" || + commandLine.startsWith("/clownfish automerge "); if (!issue.pull_request && !isAutocloseCommand) { core.info("Skipping non-autoclose command reaction because the comment is not on a pull request."); @@ -89,6 +93,12 @@ jobs: return; } + const tokenIsClownfishApp = "${{ steps.clownfish-token.outputs.token != '' }}" === "true"; + if (isClownfishCommand && !tokenIsClownfishApp) { + core.info("Skipping Clownfish command reaction because the Clownfish App token is unavailable."); + return; + } + async function react(content) { try { await github.rest.reactions.createForIssueComment({