Skip to content
This repository was archived by the owner on Nov 12, 2024. It is now read-only.

Commit a15471f

Browse files
authored
Merge pull request #1 from htunnicliff/add-ci
Add CI
2 parents c40b196 + f1ce8a4 commit a15471f

File tree

5 files changed

+54
-801
lines changed

5 files changed

+54
-801
lines changed

.github/workflows/ci.yml

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
name: CI
2+
3+
on: [push]
4+
5+
jobs:
6+
build:
7+
name: Build
8+
9+
runs-on: ubuntu-latest
10+
11+
steps:
12+
- name: Checkout
13+
uses: actions/checkout@v3
14+
15+
- name: Install Node.js
16+
uses: actions/setup-node@v3
17+
with:
18+
node-version: 16
19+
20+
- uses: pnpm/[email protected]
21+
name: Install pnpm
22+
id: pnpm-install
23+
with:
24+
version: 7
25+
run_install: false
26+
27+
- name: Get pnpm store directory
28+
id: pnpm-cache
29+
run: |
30+
echo "::set-output name=pnpm_cache_dir::$(pnpm store path)"
31+
32+
- uses: actions/cache@v3
33+
name: Setup pnpm cache
34+
with:
35+
path: ${{ steps.pnpm-cache.outputs.pnpm_cache_dir }}
36+
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
37+
restore-keys: |
38+
${{ runner.os }}-pnpm-store-
39+
40+
- name: Install dependencies
41+
run: pnpm install
42+
43+
- name: Check Formatting
44+
run: pnpm format:check
45+
46+
- name: Build
47+
run: pnpm build

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,3 +128,7 @@ dist
128128
.yarn/build-state.yml
129129
.yarn/install-state.gz
130130
.pnp.*
131+
132+
# ----
133+
134+
yarn.lock

.prettierignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
11
dist/
2+
pnpm-lock.yaml

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,8 @@
3030
"postinstall": "patch-package",
3131
"build": "del ./dist && tsc",
3232
"types:check": "tsc --noEmit",
33-
"format": "prettier --write ."
33+
"format": "prettier --write .",
34+
"format:check": "prettier --check ."
3435
},
3536
"dependencies": {
3637
"openapi-typescript-fetch": "^1.1.3"

0 commit comments

Comments
 (0)