[llvm] Add necessary permissions to release issue workflow (PR #79272)

Nikita Popov via llvm-commits llvm-commits at lists.llvm.org
Wed Jan 24 02:46:59 PST 2024


https://github.com/nikic created https://github.com/llvm/llvm-project/pull/79272

The `/cherry-pick` command needs `issues: write` to post a comment on the issue. The `/branch` command also posts a comment, and also needs `pull-requests: write` to open a PR.

This should fix the failure encountered at https://github.com/llvm/llvm-project/issues/79253#issuecomment-1907850027.

>From 503e2e3cb2ad9ce82d14370c4a06d205be8f79d6 Mon Sep 17 00:00:00 2001
From: Nikita Popov <npopov at redhat.com>
Date: Wed, 24 Jan 2024 11:45:13 +0100
Subject: [PATCH] Add necessary permissions to release issue workflow

The `/cherry-pick` command needs `issues: write` to post a comment
on the issue. The `/branch` command also posts a comment, and
also needs `pull-requests: write` to open a PR.
---
 .github/workflows/issue-release-workflow.yml | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/.github/workflows/issue-release-workflow.yml b/.github/workflows/issue-release-workflow.yml
index 1f45799af169547..3c089c5465472fc 100644
--- a/.github/workflows/issue-release-workflow.yml
+++ b/.github/workflows/issue-release-workflow.yml
@@ -33,6 +33,8 @@ jobs:
   backport-commits:
     name: Backport Commits
     runs-on: ubuntu-latest
+    permissions:
+      issues: write
     if: >-
       (github.repository == 'llvm/llvm-project') &&
       !startswith(github.event.comment.body, '<!--IGNORE-->') &&
@@ -66,6 +68,9 @@ jobs:
   create-pull-request:
     name: Create Pull Request
     runs-on: ubuntu-latest
+    permissions:
+      issues: write
+      pull-requests: write
     if: >-
       (github.repository == 'llvm/llvm-project') &&
       !startswith(github.event.comment.body, '<!--IGNORE-->') &&



More information about the llvm-commits mailing list