Repository navigation
51 lines (39 loc) · 1.46 KB
/
Copy pathdeploy.yml
File metadata and controls
51 lines (39 loc) · 1.46 KB
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
# https://docs.npmjs.com/trusted-publishers#github-actions-configuration
name: Deploy package
on:
workflow_dispatch:
push:
tags:
- "[0-9].[0-9].[0-9]"
permissions:
id-token: write # Required for OIDC
contents: read
jobs:
deploy:
runs-on: ubuntu-latest
environment: Deploy
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v4
with:
node-version: "24.x"
registry-url: "https://registry.npmjs.org"
package-manager-cache: false # never use caching in release builds
- name: Summary Head
run: |
echo "# Deployment Summary" >> $GITHUB_STEP_SUMMARY
echo "Date: $(date) " >> $GITHUB_STEP_SUMMARY
echo "Run ID: ${{ github.run_id }} " >> $GITHUB_STEP_SUMMARY
echo "Run Number: ${{ github.run_number }} " >> $GITHUB_STEP_SUMMARY
echo "Run Attempt: ${{ github.run_attempt }} " >> $GITHUB_STEP_SUMMARY
echo "Node Version: $(node --version) - NPM Version: $(npm --version) " >> $GITHUB_STEP_SUMMARY
- name: Install
run: npm ci
- name: Build
run: npm run build
- name: Lint
run: npm run lint
- name: Test
run: npm run test
- name: Publish
run: npm publish