Update to latest version of actions/github-script

See https://github.com/marketplace/actions/github-script#breaking-changes-in-v5

* Update docs to latest github-script action version
* Update CI build to latest GitHub API
This commit is contained in:
Benedikt Ritter 2022-01-16 23:45:15 +01:00 committed by GitHub
parent 42faf281e6
commit a7c463b44a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 4 deletions

View file

@ -15,11 +15,11 @@ jobs:
working-directory: __tests__/samples/kotlin-dsl working-directory: __tests__/samples/kotlin-dsl
run: ./gradlew help run: ./gradlew help
- name: "Comment build scan url" - name: "Comment build scan url"
uses: actions/github-script@v3 uses: actions/github-script@v5
with: with:
github-token: ${{secrets.GITHUB_TOKEN}} github-token: ${{secrets.GITHUB_TOKEN}}
script: | script: |
github.issues.createComment({ github.rest.issues.createComment({
issue_number: context.issue.number, issue_number: context.issue.number,
owner: context.repo.owner, owner: context.repo.owner,
repo: context.repo.repo, repo: context.repo.repo,

View file

@ -309,12 +309,12 @@ jobs:
- id: gradle - id: gradle
run: ./gradlew build run: ./gradlew build
- name: "Comment build scan url" - name: "Comment build scan url"
uses: actions/github-script@v3 uses: actions/github-script@v5
if: github.event_name == 'pull_request' && failure() if: github.event_name == 'pull_request' && failure()
with: with:
github-token: ${{secrets.GITHUB_TOKEN}} github-token: ${{secrets.GITHUB_TOKEN}}
script: | script: |
github.issues.createComment({ github.rest.issues.createComment({
issue_number: context.issue.number, issue_number: context.issue.number,
owner: context.repo.owner, owner: context.repo.owner,
repo: context.repo.repo, repo: context.repo.repo,