Skip to content

Commit 0eb7d23

Browse files
author
issayah
committed
ci: attempt again at fixing ci
1 parent 5018212 commit 0eb7d23

File tree

5 files changed

+116
-1
lines changed

5 files changed

+116
-1
lines changed

.github/workflows/ci.yaml

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,13 @@ jobs:
3333
id: pnpm-install
3434
with:
3535
version: 7
36+
run_install: false
37+
38+
- name: Get pnpm store directory
39+
id: pnpm-cache
40+
shell: bash
41+
run: |
42+
echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT
3643
3744
- name: Install dependencies
3845
run: pnpm install --ignore-scripts --frozen-lockfile
@@ -62,13 +69,64 @@ jobs:
6269
id: pnpm-install
6370
with:
6471
version: 7
72+
run_install: false
73+
74+
- name: Get pnpm store directory
75+
id: pnpm-cache
76+
shell: bash
77+
run: |
78+
echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT
6579
6680
- name: Install dependencies
6781
run: pnpm install --ignore-scripts --frozen-lockfile
6882

6983
- name: Test lint
7084
run: pnpm run test:lint
7185

86+
test-unit:
87+
runs-on: ${{ matrix.os }}
88+
89+
strategy:
90+
matrix:
91+
os: [ubuntu-latest]
92+
node-version: [16.x]
93+
94+
steps:
95+
- name: Clone repository
96+
uses: actions/checkout@v3
97+
98+
- name: Install Node.js
99+
uses: actions/setup-node@v3
100+
with:
101+
node-version: 16
102+
103+
- name: Install pnpm
104+
uses: pnpm/[email protected]
105+
id: pnpm-install
106+
with:
107+
version: 7
108+
run_install: false
109+
110+
- name: Get pnpm store directory
111+
id: pnpm-cache
112+
shell: bash
113+
run: |
114+
echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT
115+
116+
- name: Setup pnpm cache
117+
uses: actions/cache@v3
118+
with:
119+
path: ${{ steps.pnpm-cache.outputs.STORE_PATH }}
120+
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
121+
restore-keys: |
122+
${{ runner.os }}-pnpm-store-
123+
124+
- name: Install dependencies
125+
run: pnpm install --ignore-scripts --frozen-lockfile
126+
127+
- name: Test unit
128+
run: pnpm run test:unit
129+
72130
test-coverage:
73131
runs-on: ${{ matrix.os }}
74132

@@ -91,6 +149,13 @@ jobs:
91149
id: pnpm-install
92150
with:
93151
version: 7
152+
run_install: false
153+
154+
- name: Get pnpm store directory
155+
id: pnpm-cache
156+
shell: bash
157+
run: |
158+
echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT
94159
95160
- name: Install dependencies
96161
run: pnpm install --ignore-scripts --frozen-lockfile

.github/workflows/docs-github-pages-deploy.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,13 @@ jobs:
3434
id: pnpm-install
3535
with:
3636
version: 7
37+
run_install: false
38+
39+
- name: Get pnpm store directory
40+
id: pnpm-cache
41+
shell: bash
42+
run: |
43+
echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT
3744
3845
- name: Install dependencies
3946
run: pnpm install --ignore-scripts --frozen-lockfile

.github/workflows/npm-publish.yaml

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,18 +18,27 @@ jobs:
1818

1919
steps:
2020
- name: Clone repository
21+
with:
22+
ref: 'main'
2123
uses: actions/checkout@v3
2224

2325
- name: Install Node.js
2426
uses: actions/setup-node@v3
2527
with:
2628
node-version: 16
27-
29+
2830
- name: Install pnpm
2931
uses: pnpm/[email protected]
3032
id: pnpm-install
3133
with:
3234
version: 7
35+
run_install: false
36+
37+
- name: Get pnpm store directory
38+
id: pnpm-cache
39+
shell: bash
40+
run: |
41+
echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT
3342
3443
- name: Publish
3544
run: pnpm publish --tag latest --filter bootstrap-vue-3

.github/workflows/release-dev.yaml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,23 @@ jobs:
4848
id: pnpm-install
4949
with:
5050
version: 7
51+
run_install: false
52+
if: ${{ steps.release.outputs.releases_created }}
53+
54+
- name: Get pnpm store directory
55+
id: pnpm-cache
56+
shell: bash
57+
run: |
58+
echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT
59+
if: ${{ steps.release.outputs.releases_created }}
60+
61+
- uses: actions/cache@v3
62+
name: Setup pnpm cache
63+
with:
64+
path: ${{ steps.pnpm-cache.outputs.STORE_PATH }}
65+
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
66+
restore-keys: |
67+
${{ runner.os }}-pnpm-store-
5168
if: ${{ steps.release.outputs.releases_created }}
5269

5370
- name: Publish

.github/workflows/release-main.yaml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,23 @@ jobs:
4848
id: pnpm-install
4949
with:
5050
version: 7
51+
run_install: false
52+
if: ${{ steps.release.outputs.releases_created }}
53+
54+
- name: Get pnpm store directory
55+
id: pnpm-cache
56+
shell: bash
57+
run: |
58+
echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT
59+
if: ${{ steps.release.outputs.releases_created }}
60+
61+
- uses: actions/cache@v3
62+
name: Setup pnpm cache
63+
with:
64+
path: ${{ steps.pnpm-cache.outputs.STORE_PATH }}
65+
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
66+
restore-keys: |
67+
${{ runner.os }}-pnpm-store-
5168
if: ${{ steps.release.outputs.releases_created }}
5269

5370
- name: Publish

0 commit comments

Comments
 (0)