From a72a1eabcee7b389c800647d9356fc6c2dbc7dfe Mon Sep 17 00:00:00 2001 From: Leia <leia@tutamail.com> Date: Wed, 3 Jan 2024 22:38:12 -0300 Subject: [PATCH] chore: add ci --- .github/workflows/ci.yml | 60 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 00000000..c38fa4d4 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,60 @@ +name: CI + +on: + push: + pull_request: + +jobs: + server: + name: Server + runs-on: ubuntu-latest + concurrency: ci-server-${{ github.ref }} + + steps: + - name: Checkout Repository + uses: actions/checkout@v4 + + - name: Install pnpm + uses: pnpm/action-setup@v2 + with: + version: 8 + + - name: Install Node.js + uses: actions/setup-node@v4 + with: + node-version: 20 + cache: 'pnpm' + cache-dependency-path: '**/pnpm-lock.yaml' + + - name: Install Packages (Server) + run: pnpm install --frozen-lockfile + + - name: Build + run: pnpm build + lint: + name: Lint + runs-on: ubuntu-latest + concurrency: ci-lint-${{ github.ref }} + + steps: + - name: Checkout Repository + uses: actions/checkout@v4 + + - name: Install pnpm + uses: pnpm/action-setup@v2 + with: + version: 8 + + - name: Install Node.js + uses: actions/setup-node@v4 + with: + node-version: 20 + cache: 'pnpm' + cache-dependency-path: '**/pnpm-lock.yaml' + + - name: Install Packages + working-directory: ./tests + run: pnpm install --frozen-lockfile + + - name: Lint + run: pnpm lint:ci