style: share the same .prettierrc #69
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# 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://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions | |
name: Node.js CI | |
on: | |
push: | |
branches: [dev, ci-test] | |
pull_request: | |
branches: [main, dev] | |
jobs: | |
backend-build: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
node-version: [16.x, 18.x, 20.x] | |
defaults: | |
run: | |
shell: bash | |
working-directory: backend | |
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 | |
- run: pwd | |
- run: printenv | |
- run: npm ci | |
- run: npm run check-prettier | |
- run: npm test | |
env: | |
DEBUG: testcontainers* | |
- run: npm run build --if-present | |
frontend-build: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
node-version: [16.x, 18.x, 20.x] | |
defaults: | |
run: | |
shell: bash | |
working-directory: frontend | |
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: frontend/package-lock.json | |
- run: pwd | |
- run: printenv | |
- run: npm ci | |
- run: npm run check-prettier | |
- run: npm run build --if-present |