From 7992453afd007a1d60dd17696c77f8f635a3c7a8 Mon Sep 17 00:00:00 2001 From: Shumpei Wakabayashi <42209144+shmpwk@users.noreply.github.com> Date: Thu, 2 May 2024 10:12:26 +0900 Subject: [PATCH 1/2] Create comment-on-pr.yaml --- .github/workflows/comment-on-pr.yaml | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 .github/workflows/comment-on-pr.yaml diff --git a/.github/workflows/comment-on-pr.yaml b/.github/workflows/comment-on-pr.yaml new file mode 100644 index 0000000000000..5a9a463ab06ed --- /dev/null +++ b/.github/workflows/comment-on-pr.yaml @@ -0,0 +1,25 @@ +name: comment-on-pr + +on: + pull_request: + types: + - opened + branches: + - beta/v[0-9]+.[0-9]+.[0-9]+ + +jobs: + comment: + runs-on: ubuntu-latest + steps: + - name: Create comments + run: | + cat << EOF > comments + ### Merging guidelines for the beta branch + Please use `Squash and merge` as the default. + However, when incorporating multiple changes with cherry-pick, use a `Create a merge commit` to preserve the changes in the history. + EOF + - name: Post comments + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + URL: ${{ github.event.pull_request.html_url }} + run: gh pr comment -F ./comments "${URL}" From 8aac36e85efd3e9c6e58ea9403c3c2d24036fedd Mon Sep 17 00:00:00 2001 From: Shumpei Wakabayashi <42209144+shmpwk@users.noreply.github.com> Date: Thu, 2 May 2024 10:34:29 +0900 Subject: [PATCH 2/2] Update .github/workflows/comment-on-pr.yaml --- .github/workflows/comment-on-pr.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/comment-on-pr.yaml b/.github/workflows/comment-on-pr.yaml index 5a9a463ab06ed..3cfec4bf14f05 100644 --- a/.github/workflows/comment-on-pr.yaml +++ b/.github/workflows/comment-on-pr.yaml @@ -5,7 +5,7 @@ on: types: - opened branches: - - beta/v[0-9]+.[0-9]+.[0-9]+ + - beta/v0.[0-9]+.[1-9]+ jobs: comment: