Skip to content

Commit 0f61a90

Browse files
committed
ci: fix CI/CD and simplify workflows
1 parent 2aa824d commit 0f61a90

File tree

5 files changed

+61
-110
lines changed

5 files changed

+61
-110
lines changed

.github/workflows/npm-pr-review.yml

Lines changed: 0 additions & 20 deletions
This file was deleted.

.github/workflows/npm-pr.yml

Lines changed: 0 additions & 31 deletions
This file was deleted.

.github/workflows/npm-release.yml renamed to .github/workflows/release.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,14 +21,20 @@ jobs:
2121
with:
2222
fetch-depth: 0
2323
persist-credentials: false
24+
2425
- name: Setup Node.js
2526
uses: actions/setup-node@v3
2627
with:
2728
node-version: 'lts/*'
29+
registry-url: 'https://registry.npmjs.org'
30+
cache: 'npm'
31+
2832
- name: Install dependencies
29-
run: npm clean-install
33+
run: npm clean-install --ignore-scripts
34+
3035
- name: Verify the integrity of provenance attestations and registry signatures for installed dependencies
3136
run: npm audit signatures
37+
3238
- name: Release
3339
env:
3440
GITHUB_TOKEN: ${{ secrets.SNGULARBOT_TOKEN }}

.github/workflows/update-wiki.yml

Lines changed: 0 additions & 58 deletions
This file was deleted.

.github/workflows/verify.yml

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
name: Verify changes
2+
3+
on: pull_request
4+
5+
permissions:
6+
contents: read # for checkout
7+
8+
jobs:
9+
verify:
10+
name: Verify changes
11+
runs-on: ubuntu-latest
12+
steps:
13+
- name: Checkout
14+
uses: actions/checkout@v3
15+
with:
16+
fetch-depth: 0
17+
persist-credentials: false
18+
19+
- name: Setup Node.js
20+
uses: actions/setup-node@v3
21+
with:
22+
node-version: 'lts/*'
23+
registry-url: 'https://registry.npmjs.org'
24+
25+
- name: Install Dependencies
26+
run: npm install --ci
27+
28+
- name: Lint
29+
run: npm run lint
30+
tests:
31+
name: Tests
32+
runs-on: ubuntu-latest
33+
strategy:
34+
matrix:
35+
node-version: [18, 20, 'latest']
36+
os: [ubuntu-latest, macos-latest, windows-latest]
37+
steps:
38+
- name: Checkout
39+
uses: actions/checkout@v3
40+
with:
41+
fetch-depth: 0
42+
43+
- name: Setup Node.js
44+
uses: actions/setup-node@v3
45+
with:
46+
node-version: ${{ matrix.node-version }}
47+
registry-url: 'https://registry.npmjs.org'
48+
cache: 'npm'
49+
50+
- name: Install Dependencies
51+
run: npm install --ci
52+
53+
- name: Test
54+
run: npm run test

0 commit comments

Comments
 (0)