Skip to content

Commit abb8a53

Browse files
committed
ci(dependencies): make sub actions to use multiple times
1 parent 5e4007b commit abb8a53

File tree

3 files changed

+32
-30
lines changed

3 files changed

+32
-30
lines changed

.github/workflows/release.yml

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,7 @@ jobs:
1212
name: Building stack
1313

1414
steps:
15-
- name: Check out
16-
uses: actions/checkout@v4
17-
with:
18-
fetch-depth: 0
19-
20-
- name: Build ${{ matrix.projects }}
21-
run: |
22-
pnpm run build
15+
- build:
2316

2417
- name: Release
2518
uses: softprops/action-gh-release@v2

.github/workflows/setup.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: setup
2+
3+
on:
4+
workflow_dispatch:
5+
6+
jobs:
7+
setup-dependencies:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- name: "Setup pnpm"
11+
uses: pnpm/action-setup@v4
12+
13+
- name: "Setup node"
14+
uses: actions/setup-node@v4
15+
with:
16+
node-version: 23.6.0
17+
cache: "pnpm"
18+
19+
- name: "Install dependencies"
20+
run: pnpm install
21+
22+
- name: "Install emscipten"
23+
uses: "mymindstorm/setup-emsdk@v14"
24+
with:
25+
actions-cache-folder: ${{env.EM_CACHE_FOLDER}}

.github/workflows/tests.yml

Lines changed: 6 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -14,29 +14,13 @@ jobs:
1414
tests:
1515
runs-on: ubuntu-latest
1616
steps:
17-
- name: "Checkout"
18-
uses: actions/checkout@v2
19-
with:
20-
fetch-depth: 0
21-
22-
- name: "Setup pnpm"
23-
uses: pnpm/action-setup@v4
17+
- name: Checkout
18+
uses: actions/checkout@v5
2419
# with:
25-
# run_install: false
26-
27-
- name: "Setup node"
28-
uses: actions/setup-node@v4
29-
with:
30-
node-version: 23.6.0
31-
cache: "pnpm"
32-
33-
- name: "Install dependencies"
34-
run: pnpm install
35-
36-
- name: "Install emscipten"
37-
uses: "mymindstorm/setup-emsdk@v14"
38-
with:
39-
actions-cache-folder: ${{env.EM_CACHE_FOLDER}}
20+
# fetch-depth: 0
21+
22+
- name: Setup
23+
uses: './.github/workflows/setup.yml'
4024

4125
- name: "Run build"
4226
run: pnpm build

0 commit comments

Comments
 (0)