Skip to content

Commit eda277c

Browse files
committed
refactor: switch from monorepo to independent frontend and backend setups
- Removed root pnpm-lock.yaml and pnpm-workspace.yaml - Frontend and backend now manage their own dependencies independently - Updated CI workflows to run pnpm install in specific directories - Updated workflow triggers to use local lock files (frontend/pnpm-lock.yaml, backend/pnpm-lock.yaml) - Added cache-dependency-path to setup-node for each workflow - Simplified root package.json to only include prepare script for husky
1 parent 1fe0987 commit eda277c

6 files changed

Lines changed: 2518 additions & 2151 deletions

File tree

.github/workflows/backend.yml

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -8,15 +8,13 @@ on:
88
paths:
99
- 'backend/**'
1010
- '.github/workflows/backend.yml'
11-
- 'pnpm-lock.yaml'
1211
pull_request:
1312
branches:
1413
- main
1514
- develop
1615
paths:
1716
- 'backend/**'
1817
- '.github/workflows/backend.yml'
19-
- 'pnpm-lock.yaml'
2018

2119
jobs:
2220
build:
@@ -39,21 +37,22 @@ jobs:
3937
with:
4038
node-version: ${{ matrix.node-version }}
4139
cache: 'pnpm'
40+
cache-dependency-path: backend/pnpm-lock.yaml
4241

4342
- name: Install dependencies
44-
run: pnpm install --frozen-lockfile
43+
run: cd backend && pnpm install --frozen-lockfile
4544

4645
- name: Type check
47-
run: pnpm --filter backend type-check
46+
run: cd backend && pnpm type-check
4847

4948
- name: Lint
50-
run: pnpm --filter backend lint
49+
run: cd backend && pnpm lint
5150

5251
- name: Format check
53-
run: pnpm --filter backend format:check
52+
run: cd backend && pnpm format:check
5453

5554
- name: Build
56-
run: pnpm --filter backend build
55+
run: cd backend && pnpm build
5756

5857
test:
5958
runs-on: ubuntu-latest
@@ -70,10 +69,11 @@ jobs:
7069
uses: actions/setup-node@v4
7170
with:
7271
node-version: 20.x
73-
cache: 'pnpm'
72+
cache-dependency-path: backend/pnpm-lock.yaml
7473

7574
- name: Install dependencies
76-
run: pnpm install --frozen-lockfile
75+
run: cd backend && pnpm install --frozen-lockfile
7776

7877
- name: Run tests
78+
run: cd backend && pnpm
7979
run: pnpm --filter backend test 2>/dev/null || echo "No tests configured"

.github/workflows/frontend.yml

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -8,15 +8,13 @@ on:
88
paths:
99
- 'frontend/**'
1010
- '.github/workflows/frontend.yml'
11-
- 'pnpm-lock.yaml'
1211
pull_request:
1312
branches:
1413
- main
1514
- develop
1615
paths:
1716
- 'frontend/**'
1817
- '.github/workflows/frontend.yml'
19-
- 'pnpm-lock.yaml'
2018

2119
jobs:
2220
build:
@@ -39,21 +37,22 @@ jobs:
3937
with:
4038
node-version: ${{ matrix.node-version }}
4139
cache: 'pnpm'
40+
cache-dependency-path: frontend/pnpm-lock.yaml
4241

4342
- name: Install dependencies
44-
run: pnpm install --frozen-lockfile
43+
run: cd frontend && pnpm install --frozen-lockfile
4544

4645
- name: Type check
47-
run: pnpm --filter frontend type-check
46+
run: cd frontend && pnpm type-check
4847

4948
- name: Lint
50-
run: pnpm --filter frontend lint
49+
run: cd frontend && pnpm lint
5150

5251
- name: Format check
53-
run: pnpm --filter frontend format:check
52+
run: cd frontend && pnpm format:check
5453

5554
- name: Build
56-
run: pnpm --filter frontend build
55+
run: cd frontend && pnpm build
5756

5857
test:
5958
runs-on: ubuntu-latest
@@ -70,10 +69,11 @@ jobs:
7069
uses: actions/setup-node@v4
7170
with:
7271
node-version: 20.x
73-
cache: 'pnpm'
72+
cache-dependency-path: frontend/pnpm-lock.yaml
7473

7574
- name: Install dependencies
76-
run: pnpm install --frozen-lockfile
75+
run: cd frontend && pnpm install --frozen-lockfile
7776

7877
- name: Run tests
78+
run: cd frontend && pnpm
7979
run: pnpm --filter frontend test 2>/dev/null || echo "No tests configured"

0 commit comments

Comments
 (0)