Skip to content

Commit 2827b9c

Browse files
authored
chore: Node.js 16 actions are deprecated. (#4323)
The following actions uses node12 which is deprecated and will be forced to run on node16: actions/setup-node@v1, actions/cache@v1, actions/github-script@v3. - For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/ Please update the following actions to use Node.js 20: actions/stale@v3. - For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
1 parent 14ddb2b commit 2827b9c

File tree

5 files changed

+15
-15
lines changed

5 files changed

+15
-15
lines changed

.github/workflows/check-repro.yml

+6-6
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ jobs:
1010
if: ${{ github.event.label.name == 'bug' }}
1111
runs-on: ubuntu-latest
1212
steps:
13-
- uses: actions/github-script@v3
13+
- uses: actions/github-script@v7
1414
with:
1515
github-token: ${{ secrets.GITHUB_TOKEN }}
1616
script: |
@@ -23,14 +23,14 @@ jobs:
2323
'gm'
2424
);
2525
if (regex.test(body)) {
26-
await github.issues.addLabels({
26+
await github.rest.issues.addLabels({
2727
issue_number: context.issue.number,
2828
owner: context.repo.owner,
2929
repo: context.repo.repo,
3030
labels: ['repro provided'],
3131
});
3232
try {
33-
await github.issues.removeLabel({
33+
await github.rest.issues.removeLabel({
3434
issue_number: context.issue.number,
3535
owner: context.repo.owner,
3636
repo: context.repo.repo,
@@ -46,21 +46,21 @@ jobs:
4646
return;
4747
}
4848
const body = "Hey! Thanks for opening the issue. The issue doesn't seem to contain a link to a repro (a [snack.expo.dev](https://snack.expo.dev) link or link to a GitHub repo under your username).\n\nCan you provide a [minimal repro](https://stackoverflow.com/help/minimal-reproducible-example) which demonstrates the issue? A repro will help us debug the issue faster. Please try to keep the repro as small as possible and make sure that we can run it without additional setup.";
49-
const comments = await github.issues.listComments({
49+
const comments = await github.rest.issues.listComments({
5050
issue_number: context.issue.number,
5151
owner: context.repo.owner,
5252
repo: context.repo.repo,
5353
});
5454
if (comments.data.some(comment => comment.body === body)) {
5555
return;
5656
}
57-
await github.issues.createComment({
57+
await github.rest.issues.createComment({
5858
issue_number: context.issue.number,
5959
owner: context.repo.owner,
6060
repo: context.repo.repo,
6161
body,
6262
});
63-
await github.issues.addLabels({
63+
await github.rest.issues.addLabels({
6464
issue_number: context.issue.number,
6565
owner: context.repo.owner,
6666
repo: context.repo.repo,

.github/workflows/publish-each-pr.yml

+3-3
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ jobs:
4646
run: echo "EXPO_CONFIG=$(npx expo config --json)" >> $GITHUB_OUTPUT
4747

4848
- name: Comment on PR
49-
uses: actions/github-script@v3
49+
uses: actions/github-script@v7
5050
with:
5151
github-token: ${{ secrets.GITHUB_TOKEN }}
5252
script: |
@@ -62,7 +62,7 @@ jobs:
6262
<a href="${url}"><img src="https://qr.expo.dev/eas-update?appScheme=exp&projectId=${projectId}&channel=${channel}&runtimeVersion=exposdk:${sdkVersion}&host=u.expo.dev" height="200px" width="200px"></a>
6363
`;
6464
65-
const comments = await github.issues.listComments({
65+
const comments = await github.rest.issues.listComments({
6666
issue_number: context.issue.number,
6767
owner: context.repo.owner,
6868
repo: context.repo.repo,
@@ -72,7 +72,7 @@ jobs:
7272
return;
7373
}
7474
75-
github.issues.createComment({
75+
github.rest.issues.createComment({
7676
issue_number: context.issue.number,
7777
owner: context.repo.owner,
7878
repo: context.repo.repo,

.github/workflows/semantic-pr.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: "Semantic Pull Request"
1+
name: Semantic Pull Request
22
on: [pull_request]
33

44
jobs:
@@ -10,4 +10,4 @@ jobs:
1010
env:
1111
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
1212
with:
13-
validateSingleCommit: true
13+
validateSingleCommit: true

.github/workflows/stale.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ jobs:
88
stale:
99
runs-on: ubuntu-latest
1010
steps:
11-
- uses: actions/stale@v3
11+
- uses: actions/stale@v9
1212
with:
1313
repo-token: ${{ secrets.GITHUB_TOKEN }}
1414
days-before-stale: 30

.github/workflows/updates.yml

+3-3
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@ jobs:
1010
runs-on: ubuntu-latest
1111
steps:
1212
- name: Checkout
13-
uses: actions/checkout@v2
13+
uses: actions/checkout@v4
1414

1515
- name: Setup Node.js
16-
uses: actions/setup-node@v2
16+
uses: actions/setup-node@v4
1717
with:
1818
node-version: 16.x
1919

@@ -28,7 +28,7 @@ jobs:
2828
id: yarn-cache-path
2929
run: echo "::set-output name=dir::$(yarn cache dir)"
3030

31-
- uses: actions/cache@v2
31+
- uses: actions/cache@v4
3232
with:
3333
path: ${{ steps.yarn-cache-path.outputs.dir }}
3434
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}

0 commit comments

Comments
 (0)