Skip to content

Commit 4c0a13a

Browse files
committed
refactor: update release workflow to checkout code with fetch-depth 0 and update dependencies
1 parent f440916 commit 4c0a13a

File tree

1 file changed

+17
-38
lines changed

1 file changed

+17
-38
lines changed

.github/workflows/release.yml

Lines changed: 17 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -1,63 +1,45 @@
1-
name: The Best Release Pipeline, Believe Me!
2-
1+
name: Release Workflow
32
on:
43
push:
54
branches:
65
- main
7-
86
concurrency: ${{ github.workflow }}-${{ github.ref }}
97

108
jobs:
11-
setup:
12-
name: Setup Environment, Let’s Do This First!
9+
release:
10+
name: Checkout and Setup
1311
runs-on: ubuntu-latest
14-
outputs:
15-
store_path: ${{ steps.store.outputs.store_path }}
1612
steps:
17-
- name: Checkout the Greatest Code, Nobody Does It Better!
13+
- name: Checkout Repository
1814
uses: actions/checkout@v4
1915
with:
2016
fetch-depth: 0
2117

22-
- name: Setting Up Node.js 20.x, It's a Perfect Node Version!
18+
- name: Setup Node.js 20.x Environment
2319
uses: actions/setup-node@v4
2420
with:
2521
node-version: 20
2622

27-
- name: Installing pnpm, It's the Best Package Manager, Everyone Knows It!
23+
- name: Install pnpm Package Manager
2824
uses: pnpm/action-setup@v4
2925
with:
3026
run_install: false
3127

32-
- name: Finding the pnpm Store, The Best Store, It's Yuge!
33-
id: store
28+
- name: Get pnpm Store Directory
3429
shell: bash
35-
run: echo "store_path=$(pnpm store path --silent)" >> $GITHUB_ENV && echo "::set-output name=store_path::$(pnpm store path --silent)"
30+
run: echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
3631

37-
- name: Caching pnpm Store, We Love Saving Time, Don’t We?
32+
- name: Cache pnpm Store Directory
3833
uses: actions/cache@v4
3934
with:
40-
path: ${{ steps.store.outputs.store_path }}
35+
path: ${{ env.STORE_PATH }}
4136
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
4237
restore-keys: ${{ runner.os }}-pnpm-store-
4338

44-
- name: Installing Dependencies, Faster Than Anyone Thought Possible!
39+
- name: Install Project Dependencies
4540
run: pnpm install
4641

47-
release:
48-
name: Release the Package, It’s Show Time!
49-
runs-on: ubuntu-latest
50-
needs: setup
51-
steps:
52-
- name: Checkout the Greatest Code, Nobody Does It Better!
53-
uses: actions/checkout@v4
54-
with:
55-
fetch-depth: 0
56-
57-
- name: Installing Dependencies, It's Already Setup, So Fast!
58-
run: pnpm install --frozen-lockfile
59-
60-
- name: Create Release PR or Publish the Greatest Package Ever!
42+
- name: Create Release Pull Request or Publish Package
6143
id: changesets
6244
uses: changesets/action@v1
6345
with:
@@ -67,22 +49,19 @@ jobs:
6749
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
6850

6951
chromatic:
70-
name: Running Chromatic, Visual Tests So Good, They’ll Blow Your Mind!
52+
name: Run Chromatic Visual Tests
7153
runs-on: ubuntu-latest
72-
needs: setup
54+
needs: release
7355
steps:
74-
- name: Checkout the Greatest Code, Nobody Does It Better!
56+
- name: Checkout Repository
7557
uses: actions/checkout@v4
7658
with:
7759
fetch-depth: 0
7860

79-
- name: Installing Dependencies, It's Already Setup, So Fast!
80-
run: pnpm install --frozen-lockfile
81-
82-
- name: Running Chromatic, Visual Tests So Good, They’ll Blow Your Mind!
61+
- name: Run Chromatic Visual Tests
8362
uses: chromaui/action@latest
8463
with:
8564
projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
8665
workingDir: apps/docs
8766
onlyChanged: true
88-
zip: true
67+
zip:

0 commit comments

Comments
 (0)