Skip to content

Commit 06eddc3

Browse files
committed
chore: switch build to yarn
1 parent d038537 commit 06eddc3

File tree

2 files changed

+16
-31
lines changed

2 files changed

+16
-31
lines changed

.github/workflows/main.yml

+11-26
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,9 @@ jobs:
3131
uses: actions/setup-node@v1
3232
with:
3333
node-version: ${{ matrix.node-version }}
34+
cache: yarn
3435
- name: npm install
35-
run: npm ci
36+
run: yarn
3637
- name: Build
3738
run: |
3839
./node_modules/.bin/tsc --build \
@@ -109,13 +110,9 @@ jobs:
109110
uses: actions/setup-node@v1
110111
with:
111112
node-version: ${{ matrix.node-version }}
112-
- name: Cache node_modules
113-
uses: actions/cache@v1
114-
with:
115-
path: '**/node_modules'
116-
key: ${{ runner.os }}-postgres-node_modules-${{ hashFiles('**/package-lock.json') }}
113+
cache: yarn
117114
- name: npm install
118-
run: npm ci
115+
run: yarn
119116
- name: Build
120117
run: |
121118
./node_modules/.bin/tsc --build packages/postgres/tsconfig.json;
@@ -147,13 +144,9 @@ jobs:
147144
uses: actions/setup-node@v1
148145
with:
149146
node-version: ${{ matrix.node-version }}
150-
- name: Cache node_modules
151-
uses: actions/cache@v1
152-
with:
153-
path: '**/node_modules'
154-
key: ${{ runner.os }}-mysql-node_modules-${{ hashFiles('**/package-lock.json') }}
147+
cache: yarn
155148
- name: npm install
156-
run: npm ci
149+
run: yarn
157150
- name: Build
158151
run: |
159152
./node_modules/.bin/tsc --build packages/mysql/tsconfig.json
@@ -175,13 +168,9 @@ jobs:
175168
uses: actions/setup-node@v1
176169
with:
177170
node-version: ${{ matrix.node-version }}
178-
- name: Cache node_modules
179-
uses: actions/cache@v1
180-
with:
181-
path: '**/node_modules'
182-
key: ${{ runner.os }}-sqlite-node_modules-${{ hashFiles('**/package-lock.json') }}
171+
cache: yarn
183172
- name: npm install
184-
run: npm ci
173+
run: yarn
185174
- name: Build
186175
run: |
187176
./node_modules/.bin/tsc --build packages/sqlite/tsconfig.json
@@ -221,13 +210,9 @@ jobs:
221210
uses: actions/setup-node@v1
222211
with:
223212
node-version: ${{ matrix.node-version }}
224-
- name: Cache node_modules
225-
uses: actions/cache@v1
226-
with:
227-
path: '**/node_modules'
228-
key: ${{ runner.os }}-mongo-node_modules-${{ hashFiles('**/package-lock.json') }}
229-
- name: npm install
230-
run: npm ci
213+
cache: yarn
214+
- name: yarn
215+
run: yarn
231216
- name: Build
232217
run: |
233218
./node_modules/.bin/tsc --build packages/mongo/tsconfig.json

lefthook.yml

+5-5
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@ commit-msg:
55
run: npx commitlint --edit {1}
66
pre-commit:
77
commands:
8-
github-actions:
9-
glob: '*.{yaml,yml}'
10-
root: '.github'
11-
run: echo {staged_files} && actionlint
8+
# github-actions:
9+
# glob: '*.{yaml,yml}'
10+
# root: '.github'
11+
# run: echo {staged_files} && actionlint
1212
prettier:
1313
glob: '[*.{json,yml,yaml,html,ts,tsx,js,jsx},!./package-lock.json]'
14-
run: npx prettier --write {staged_files} && git add {staged_files}
14+
run: ./node_modules/.bin/prettier --write {staged_files} && git add {staged_files}

0 commit comments

Comments
 (0)