manaba-enhanced-for-tsukuba/manaba-enhanced

View on GitHub
.github/workflows/ci.yaml

Summary

Maintainability
Test Coverage
name: CI

on:
  push:
    branches:
      - main
  pull_request:

env:
  MAKE_YARN_FROZEN_LOCKFILE: 1

jobs:
  Lint:
    name: Lint
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v3
        with:
          fetch-depth: 0
      - name: Use Node.js
        uses: actions/setup-node@v3
        with:
          node-version: "18"
      - uses: actions/cache@v3
        with:
          path: "**/node_modules"
          key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }}
      - name: Install dependencies
        run: make node_modules
      - uses: wagoid/commitlint-github-action@v5
      - name: Run Lint
        run: make lint
      - name: Run Prettier
        run: make format.check
      - name: Run typecheck
        run: make typecheck

  build:
    name: Build
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v3
      - name: Use Node.js
        uses: actions/setup-node@v3
        with:
          node-version: "18"
      - uses: actions/cache@v3
        with:
          path: "**/node_modules"
          key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }}
      - name: Build for Chrome
        run: make build.chrome
      - name: Build for Firefox
        run: make build.firefox