Skip to content

Commit

Permalink
ci: newer Octokit requires the .rest. qualifier
Browse files Browse the repository at this point in the history
It is no longer enough to call `github.users.listGpgKeysForUser()`, it
needs to specify the REST API mode (as opposed to GraphQL):
`github.rest.users.listGpgKeysForUser()`.

This was highly recommended before upgrading to
`actions/github-script@v6`, but now is required.

Signed-off-by: Johannes Schindelin <[email protected]>
  • Loading branch information
dscho committed Nov 21, 2022
1 parent 394c35a commit cbf3e59
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/release-tag.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
script: |
const { execSync } = require('child_process')
for (const { key_id, raw_key } of (await github.users.listGpgKeysForUser({
for (const { key_id, raw_key } of (await github.rest.users.listGpgKeysForUser({
username: 'dscho'
})).data) {
execSync(`gpg ${raw_key ? '--import' : `--recv-keys ${key_id}`}`,
Expand Down Expand Up @@ -73,7 +73,7 @@ jobs:
const { readFileSync } = require('fs')
const tag_name = readFileSync('tag_name').toString()
await github.repos.createRelease({
await github.rest.repos.createRelease({
owner: context.repo.owner,
repo: context.repo.repo,
tag_name: tag_name,
Expand Down

0 comments on commit cbf3e59

Please sign in to comment.