Skip to content

Commit

Permalink
use turbo for building
Browse files Browse the repository at this point in the history
  • Loading branch information
sitek94 committed Nov 26, 2023
1 parent 340e57d commit ca9b204
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 34 deletions.
30 changes: 12 additions & 18 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ jobs:
run: pnpm test:e2e

build:
name: 🏗️ Build apps
name: 🏗️ Build
needs: [changes]
runs-on: ubuntu-latest
steps:
Expand All @@ -164,8 +164,14 @@ jobs:
- name: 📥 Install Dependencies
run: pnpm install

- name: 🏗️ Build apps
run: pnpm build:apps
- name: 🏗️ Build
run: pnpm build

- uses: actions/upload-artifact@v3
if: needs.changes.outputs.docs == 'true'
with:
name: docs-artifacts
path: ./apps/docs/build

deploy-nestjs:
name: 🐯 Deploy NestJS App
Expand Down Expand Up @@ -217,22 +223,10 @@ jobs:
with:
fetch-depth: 0

- name: Setup pnpm
uses: pnpm/[email protected]
- name: Download docs artifacts
uses: actions/download-artifact@v3
with:
version: 8

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: pnpm

- name: 📥 Install Dependencies
run: pnpm install

- name: 🏗️ Build
run: pnpm build:docs
name: docs-artifacts

- name: 🚀 Deploy to Chromatic
uses: chromaui/action@v1
Expand Down
21 changes: 5 additions & 16 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,29 +2,18 @@
"name": "pnpm-monorepo",
"private": true,
"scripts": {
"build:apps": "pnpm --filter {'./apps/*'}... run build",
"build:docs": "pnpm -F docs... build",
"build:nestjs": "pnpm -F nestjs... build",
"build:remix": "pnpm -F remix... build",
"build:ui": "pnpm -F ui build",
"build": "turbo run build",
"clean": "pnpx rimraf **/dist && pnpx rimraf **/node_modules && pnpx rimraf **/build",
"deploy:nestjs": "fly deploy --config ./apps/nestjs/fly.toml --dockerfile ./apps/nestjs/Dockerfile",
"deploy:remix": "fly deploy --config ./apps/remix/fly.toml --dockerfile ./apps/remix/Dockerfile",
"develop:docs": "pnpm -F docs develop",
"develop:nestjs": "pnpm -F nestjs develop",
"develop:remix": "pnpm -F remix... develop",
"develop:ui": "pnpm -F ui develop",
"develop": "pnpm -r develop",
"develop:docs": "turbo run develop --filter docs",
"develop:nestjs": "turbo run develop --filter nestjs",
"develop:remix": "turbo run develop --filter remix",
"develop:ui": "turbo run develop --filter ui",
"develop": "turbo run develop",
"format": "prettier --write .",
"lint": "turbo run lint",
"start:docs": "pnpm -F docs start",
"start:nestjs": "pnpm -F nestjs start",
"start:remix": "pnpm -F remix start",
"start": "pnpm -r start",
"test": "turbo run test",
"test:e2e": "turbo run test:e2e",
"test:nestjs": "pnpm -F nestjs test",
"typecheck": "turbo run typecheck"
},
"devDependencies": {
Expand Down

0 comments on commit ca9b204

Please sign in to comment.