generated from n8n-io/n8n-nodes-starter
-
Notifications
You must be signed in to change notification settings - Fork 2
38 lines (36 loc) · 1002 Bytes
/
ci.yaml
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
name: Build and upload the artifacts
on:
push:
branches: [ "*" ]
paths-ignore:
- README.md
- images/*
pull_request:
branches: [ "*" ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20
- name: Get metadata
id: metadata
run: |
echo node-version=$(node -e "console.log(require('./package.json').version)") >> $GITHUB_OUTPUT
echo node-id=$(node -e "console.log(require('./package.json').name)") >> $GITHUB_OUTPUT
- name: Set up pnpm
run: corepack enable pnpm
- name: Install dependencies
run: pnpm install
- name: Lint
run: pnpm run lint
- name: Build
run: pnpm run build
- name: Upload build artifacts
uses: actions/upload-artifact@v4
with:
name: ${{ steps.metadata.outputs.node-id }}-${{ steps.metadata.outputs.node-version }}
path: dist
retention-days: 3