Skip to content

Commit

Permalink
Merge pull request #776 from dscho/update-to-github-script@v7
Browse files Browse the repository at this point in the history
Update to `actions/github-script@v7`
  • Loading branch information
dscho authored Nov 15, 2023
2 parents a667737 + 03f14ce commit 44e6ddb
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/release-tag.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,13 @@ jobs:
token: ${{ secrets.PUSH_RELEASE_TRAINS_PAT }}
fetch-depth: 0
- name: Import public GPG keys to verify the tag
uses: actions/github-script@v3
uses: actions/github-script@v7
with:
github-token: ${{secrets.GITHUB_TOKEN}}
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 @@ -66,14 +66,14 @@ jobs:
git cat-file tag "$GITHUB_REF" | sed -e '1,/^$/d' -e '/-----BEGIN PGP SIGNATURE-----/,$d' >body
- name: Create Release
if: github.repository_owner == 'git-for-windows'
uses: actions/github-script@v3
uses: actions/github-script@v7
with:
github-token: ${{secrets.GITHUB_TOKEN}}
script: |
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 44e6ddb

Please sign in to comment.