Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: setup CI/CD #66

Merged
merged 11 commits into from
Mar 1, 2024
37 changes: 37 additions & 0 deletions .github/workflows/node.js.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs

name: Node.js CI

on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]

jobs:
build:

runs-on: ubuntu-latest

strategy:
matrix:
node-version: [14.x, 16.x, 18.x]
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/

steps:
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
cache-dependency-path: |
backend/package-lock.json
frontend/package-lock.json
- run: npm --prefix ./backend ci
- run: npm --prefix ./backend run build --if-present
# - run: npm --prefix ./backend test
- run: npm --prefix ./frontend ci
- run: npm --prefix ./frontend run build --if-present
# - run: npm --prefix ./frontend test
6 changes: 5 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@
# production
*/build

# db
*.db

# misc
*.DS_Store
*.env.local
Expand All @@ -20,4 +23,5 @@

*npm-debug.log*
*yarn-debug.log*
*yarn-error.log*
*yarn-error.log*
.vscode/*
Loading
Loading