-
Notifications
You must be signed in to change notification settings - Fork 0
52 lines (39 loc) · 1.31 KB
/
ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
name: is.js CICD
on: [push, pull_request, workflow_dispatch]
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: read
id-token: write
strategy:
matrix:
node-version: [14, 16, 18, 20]
name: is.js - nodeJS v${{ matrix.node-version }}
steps:
- name: Checkout Repo
uses: actions/checkout@v4
- name: Setup node v${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- name: Init - node v${{ matrix.node-version }}
run: yarn --frozen-lockfile --non-interactive
- name: Lint - node v${{ matrix.node-version }}
run: yarn lint
- name: Test - node v${{ matrix.node-version }}
run: yarn test
- name: Package - node v${{ matrix.node-version }}
run: yarn build
- name: Validation - node v${{ matrix.node-version }}
run: npm install kj4ezj-is-*.tgz
- name: Upload Artifacts
uses: actions/upload-artifact@v4
with:
name: kj4ezj-is-${{ matrix.node-version }}
path: kj4ezj-is-*.tgz
- name: Publish to NPM
run: npm publish --provenance --access public
if: startsWith(github.ref, 'refs/tags/')
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_API_KEY }}