Skip to content

Commit

Permalink
ci: Fix imports in 'actions/github-script' (#3626)
Browse files Browse the repository at this point in the history
  • Loading branch information
IvanGoncharov authored Jun 3, 2022
1 parent fdc3555 commit 2fb6eca
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/cmd-publish-pr-on-npm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,8 @@ jobs:
uses: actions/github-script@v6
with:
script: |
import fs from 'node:fs';
import assert from 'node:assert';
const fs = require('node:fs');
const assert = require('node:assert');
const pull_request = JSON.parse(process.env.PULL_REQUEST_JSON);
const packageJSONPath = './npmDist/package.json';
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/cmd-run-benchmark.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ jobs:
uses: actions/github-script@v6
with:
script: |
import fs from 'node:fs';
const fs = require('node:fs');
// GH doesn't expose job's id so we need to get it through API, see
// https://github.community/t/job-id-is-string-in-github-job-but-integer-in-actions-api/139060
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/github-actions-bot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ jobs:
uses: actions/github-script@v6
with:
script: |
import fs from 'node:fs';
const fs = require('node:fs');
const event = JSON.parse(fs.readFileSync('./event.json', 'utf8'));
await github.rest.issues.createComment({
Expand Down Expand Up @@ -110,7 +110,7 @@ jobs:
uses: actions/github-script@v6
with:
script: |
import fs from 'node:fs';
const fs = require('node:fs');
const needs = JSON.parse(process.env.NEEDS);
Expand All @@ -134,7 +134,7 @@ jobs:
uses: actions/github-script@v6
with:
script: |
import fs from 'node:fs';
const fs = require('node:fs');
const replyMessage = fs.readFileSync('./replyMessage.txt', 'utf-8');
const { issue, comment, sender } = context.payload;
Expand Down

0 comments on commit 2fb6eca

Please sign in to comment.