Skip to content

Commit d72f880

Browse files
chore(trusted-publishing): initial commit to add github actions to support OIDC trusted publishing.
1. Added github actions: main, check, build, notify-failure and release 2. Added a new channel testing-oidc-trusted-publishing for testing npmjs package deployments
1 parent eeb6215 commit d72f880

File tree

10 files changed

+2578
-1382
lines changed

10 files changed

+2578
-1382
lines changed

.circleci/config.yml

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

.github/workflows/build.yaml

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
name: Build
2+
3+
permissions:
4+
contents: read
5+
6+
on:
7+
workflow_call:
8+
9+
jobs:
10+
build:
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- name: Checkout code
15+
uses: actions/checkout@v5
16+
17+
- name: Setup Node.js
18+
uses: actions/setup-node@v6
19+
with:
20+
node-version: '24'
21+
cache: 'npm'
22+
23+
- name: Install latest npm
24+
run: npm install -g npm@latest
25+
26+
- name: Install dependencies
27+
run: npm ci
28+
29+
# required for browser output-integration tests
30+
- name: Setup Chrome
31+
uses: browser-actions/setup-chrome@v2
32+
with:
33+
install-chromedriver: true
34+
35+
- name: Build
36+
run: npm run build
37+
env:
38+
# required for browser output-integration tests
39+
PUPPETEER_EXECUTABLE_PATH: /usr/bin/google-chrome
40+
41+
- name: Save Build folders
42+
uses: actions/cache/save@v4
43+
with:
44+
path: |
45+
dist
46+
key: build-cache-${{ github.run_id }}-${{ github.run_attempt }}

.github/workflows/check.yaml

Lines changed: 139 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,139 @@
1+
name: Run Checks
2+
3+
permissions:
4+
contents: read
5+
6+
on:
7+
workflow_call:
8+
9+
jobs:
10+
lint:
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- name: Checkout code
15+
uses: actions/checkout@v5
16+
17+
- name: Setup Node.js
18+
uses: actions/setup-node@v6
19+
with:
20+
node-version: '24'
21+
cache: 'npm'
22+
23+
- name: Install latest npm
24+
run: npm install -g npm@latest
25+
26+
- name: Install dependencies
27+
run: npm ci
28+
29+
- name: Run linter
30+
run: npm run lint
31+
32+
prettier:
33+
runs-on: ubuntu-latest
34+
35+
steps:
36+
- name: Checkout code
37+
uses: actions/checkout@v5
38+
39+
- name: Setup Node.js
40+
uses: actions/setup-node@v6
41+
with:
42+
node-version: '24'
43+
cache: 'npm'
44+
45+
- name: Install latest npm
46+
run: npm install -g npm@latest
47+
48+
- name: Install dependencies
49+
run: npm ci
50+
51+
- name: Check prettier formatting
52+
run: npm run prettier:check
53+
54+
test:
55+
runs-on: ubuntu-latest
56+
57+
steps:
58+
- name: Checkout code
59+
uses: actions/checkout@v5
60+
61+
- name: Setup Node.js
62+
uses: actions/setup-node@v6
63+
with:
64+
node-version: '24'
65+
cache: 'npm'
66+
67+
- name: Install latest npm
68+
run: npm install -g npm@latest
69+
70+
- name: Install dependencies
71+
run: npm ci
72+
73+
- name: Restore the build folders
74+
uses: actions/cache/restore@v4
75+
with:
76+
path: |
77+
dist
78+
key: build-cache-${{ github.run_id }}-${{ github.run_attempt }}
79+
80+
- name: Run tests
81+
run: npm test
82+
83+
test-bundle-size:
84+
runs-on: ubuntu-latest
85+
86+
steps:
87+
- name: Checkout code
88+
uses: actions/checkout@v5
89+
90+
- name: Setup Node.js
91+
uses: actions/setup-node@v6
92+
with:
93+
node-version: '24'
94+
cache: 'npm'
95+
96+
- name: Install latest npm
97+
run: npm install -g npm@latest
98+
99+
- name: Install dependencies
100+
run: npm ci
101+
102+
- name: Restore the build folders
103+
uses: actions/cache/restore@v4
104+
with:
105+
path: |
106+
dist
107+
key: build-cache-${{ github.run_id }}-${{ github.run_attempt }}
108+
109+
- name: Test bundle size
110+
run: npm run test:size
111+
112+
test-types:
113+
runs-on: ubuntu-latest
114+
115+
steps:
116+
- name: Checkout code
117+
uses: actions/checkout@v5
118+
119+
- name: Setup Node.js
120+
uses: actions/setup-node@v6
121+
with:
122+
node-version: '24'
123+
cache: 'npm'
124+
125+
- name: Install latest npm
126+
run: npm install -g npm@latest
127+
128+
- name: Install dependencies
129+
run: npm ci
130+
131+
- name: Restore the build folders
132+
uses: actions/cache/restore@v4
133+
with:
134+
path: |
135+
dist
136+
key: build-cache-${{ github.run_id }}-${{ github.run_attempt }}
137+
138+
- name: Test TypeScript types
139+
run: npm run test:types

.github/workflows/codeql.yml renamed to .github/workflows/codeql.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,14 +19,14 @@ jobs:
1919
security-events: write
2020

2121
steps:
22-
- uses: actions/checkout@v4
22+
- uses: actions/checkout@v5
2323

2424
- name: Initialize CodeQL
25-
uses: github/codeql-action/init@v3
25+
uses: github/codeql-action/init@v4
2626
with:
2727
languages: actions
2828

2929
- name: Run CodeQL Analysis
30-
uses: github/codeql-action/analyze@v3
30+
uses: github/codeql-action/analyze@v4
3131
with:
3232
category: actions

0 commit comments

Comments
 (0)