Skip to content

Commit b2d3739

Browse files
committed
chore(ci): configured github workflows
1 parent 9232779 commit b2d3739

File tree

2 files changed

+56
-0
lines changed

2 files changed

+56
-0
lines changed

.github/actions/install/action.yml

+22
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
name: 'Setup Node.js with PNPM'
2+
description: 'Common installation for Node.js and PNPM'
3+
4+
runs:
5+
using: composite
6+
steps:
7+
- uses: pnpm/action-setup@v3
8+
with:
9+
run_install: false
10+
11+
- uses: actions/setup-node@v4
12+
with:
13+
cache: 'pnpm'
14+
node-version-file: '.nvmrc'
15+
16+
- name: Preinstallation steps
17+
shell: bash
18+
run: corepack enable
19+
20+
- name: Install dependencies
21+
shell: bash
22+
run: pnpm i --frozen-lockfile

.github/workflows/ci.yml

+34
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
name: ci
2+
on:
3+
push:
4+
branches:
5+
- main
6+
pull_request:
7+
branches:
8+
- main
9+
10+
jobs:
11+
check:
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/checkout@v4
15+
with:
16+
fetch-depth: 0
17+
- uses: ./.github/actions/install
18+
- run: pnpm check
19+
prettier:
20+
runs-on: ubuntu-latest
21+
steps:
22+
- uses: actions/checkout@v4
23+
with:
24+
fetch-depth: 0
25+
- uses: ./.github/actions/install
26+
- run: pnpm prettier --check .
27+
test:
28+
runs-on: ubuntu-latest
29+
steps:
30+
- uses: actions/checkout@v4
31+
with:
32+
fetch-depth: 0
33+
- uses: ./.github/actions/install
34+
- run: pnpm test

0 commit comments

Comments
 (0)