Only add PR comments for internal PR (#7448)
* Add write permission for issues * Add write permission to PRs * Update ChangeLog * Fixed ChangeLog version * Correct ChangeLog * Remove GITHUB_TOKEN input * Revert "Remove GITHUB_TOKEN input" This reverts commit e868a8d3f4b753f758b4b2bd25aef78e4d4d62d7. * Use COMMENT_PAT for GITHUB_TOKEN * Use default permissions * Only use `sticky-pull-request-comment` for internal PRs * Update ChangeLog
This commit is contained in:
9
.github/actions/run-tests-setup/action.yml
vendored
9
.github/actions/run-tests-setup/action.yml
vendored
@ -1,11 +1,6 @@
|
||||
name: "Run tests (setup)"
|
||||
description: "Sets up the PR comment for tests"
|
||||
|
||||
inputs:
|
||||
GITHUB_TOKEN:
|
||||
description: "The GitHub token to use for authentication"
|
||||
required: true
|
||||
|
||||
runs:
|
||||
using: "composite"
|
||||
|
||||
@ -19,8 +14,8 @@ runs:
|
||||
|
||||
- name: Begin PR comment
|
||||
uses: marocchino/sticky-pull-request-comment@v2
|
||||
if: github.event.pull_request.head.repo.full_name == github.repository
|
||||
with:
|
||||
GITHUB_TOKEN: ${{ inputs.GITHUB_TOKEN }}
|
||||
header: tests
|
||||
recreate: true
|
||||
message: |
|
||||
@ -30,8 +25,8 @@ runs:
|
||||
# Neccesary since the first comment has an annoying comment.
|
||||
- name: Append table header
|
||||
uses: marocchino/sticky-pull-request-comment@v2
|
||||
if: github.event.pull_request.head.repo.full_name == github.repository
|
||||
with:
|
||||
GITHUB_TOKEN: ${{ inputs.GITHUB_TOKEN }}
|
||||
header: tests
|
||||
append: true
|
||||
message: |
|
||||
|
||||
6
.github/actions/run-tests/action.yml
vendored
6
.github/actions/run-tests/action.yml
vendored
@ -2,10 +2,6 @@ name: "Run tests"
|
||||
description: "Runs both unit tests and integration tests and appends to a PR comment"
|
||||
|
||||
inputs:
|
||||
GITHUB_TOKEN:
|
||||
description: "The GitHub token to use for authentication"
|
||||
required: true
|
||||
|
||||
job:
|
||||
description: "The job name to append to the PR comment"
|
||||
default: "unknown"
|
||||
@ -51,8 +47,8 @@ runs:
|
||||
|
||||
- name: Append to PR comment
|
||||
uses: marocchino/sticky-pull-request-comment@v2
|
||||
if: github.event.pull_request.head.repo.full_name == github.repository
|
||||
with:
|
||||
GITHUB_TOKEN: ${{ inputs.GITHUB_TOKEN }}
|
||||
header: tests
|
||||
append: true
|
||||
message: |
|
||||
|
||||
7
.github/workflows/ci.yml
vendored
7
.github/workflows/ci.yml
vendored
@ -19,7 +19,7 @@ on:
|
||||
release:
|
||||
types: [published]
|
||||
schedule:
|
||||
- cron: "0 5 * * *"
|
||||
- cron: "0 5 * * *" # 5am UTC
|
||||
|
||||
env:
|
||||
GIT_SHA: ${{ github.sha }}
|
||||
@ -43,8 +43,6 @@ jobs:
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- uses: ./.github/actions/run-tests-setup
|
||||
with:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
windows:
|
||||
name: ${{ matrix.target.name }}
|
||||
@ -96,7 +94,6 @@ jobs:
|
||||
uses: ./.github/actions/run-tests
|
||||
timeout-minutes: 2
|
||||
with:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
job: ${{ matrix.target.name }}
|
||||
|
||||
- name: Package
|
||||
@ -171,7 +168,6 @@ jobs:
|
||||
uses: ./.github/actions/run-tests
|
||||
timeout-minutes: 2
|
||||
with:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
job: ${{ matrix.target.name }}
|
||||
|
||||
- name: Package
|
||||
@ -288,7 +284,6 @@ jobs:
|
||||
uses: ./.github/actions/run-tests
|
||||
timeout-minutes: 2
|
||||
with:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
job: linux-${{ matrix.distro.name }}
|
||||
|
||||
- name: Package
|
||||
|
||||
3
.github/workflows/sonarcloud-analysis.yml
vendored
3
.github/workflows/sonarcloud-analysis.yml
vendored
@ -111,5 +111,4 @@ jobs:
|
||||
-Dsonar.cfamily.threads=${{ env.CPU_CORE_COUNT }} \
|
||||
-Dsonar.python.version=3.10
|
||||
env:
|
||||
SONAR_TOKEN: ${{secrets.SONAR_TOKEN}}
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
|
||||
|
||||
2
.github/workflows/valgrind-analysis.yml
vendored
2
.github/workflows/valgrind-analysis.yml
vendored
@ -56,8 +56,8 @@ jobs:
|
||||
|
||||
- name: Append to PR comment
|
||||
uses: marocchino/sticky-pull-request-comment@v2
|
||||
if: github.event.pull_request.head.repo.full_name == github.repository
|
||||
with:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
recreate: true
|
||||
header: valgrind
|
||||
message: |
|
||||
|
||||
Reference in New Issue
Block a user