From 75711cf7068d5257748fbc6345c44117b7444a92 Mon Sep 17 00:00:00 2001 From: Martin Cayuelas Date: Tue, 22 Aug 2023 12:08:59 +0200 Subject: [PATCH] Init Actions --- .github/workflows/checks.yml | 33 +++++++++++++++++++++++++++ .github/workflows/deploy.yml | 43 ------------------------------------ 2 files changed, 33 insertions(+), 43 deletions(-) create mode 100644 .github/workflows/checks.yml delete mode 100644 .github/workflows/deploy.yml diff --git a/.github/workflows/checks.yml b/.github/workflows/checks.yml new file mode 100644 index 00000000..05723f18 --- /dev/null +++ b/.github/workflows/checks.yml @@ -0,0 +1,33 @@ +name: Code Checks + +on: + push: + branches: [ main ] + pull_request: + branches: [ main ] + +jobs: + deploy: + name: Code checks + runs-on: ubuntu-latest + steps: + - name: Checkout project + uses: actions/checkout@v3 + + - name: Setup node + uses: actions/setup-node@v3 + with: + node-version: 18.x + + - name: Install dependencies + run: yarn install --immutable --immutable-cache --check-cache --frozen-lockfile + + - name: Run tests + run: yarn test + + - name: Run linter + run: yarn lint + + - name: Run typescript + run: npx tsc + diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml deleted file mode 100644 index 0aae77ba..00000000 --- a/.github/workflows/deploy.yml +++ /dev/null @@ -1,43 +0,0 @@ -name: Deploy to Vercel - -on: - pull_request: - branches: - - development - - master - push: - branches: - - development - - master - -jobs: - deploy: - name: Code checks and Deploy - runs-on: ubuntu-latest - steps: - - name: Checkout project - uses: actions/checkout@v3 - - - name: Setup node - uses: actions/setup-node@v3 - with: - node-version: 16.x - - - name: Install dependencies - run: yarn install --immutable --immutable-cache --check-cache --frozen-lockfile - - - name: Run tests - run: yarn test:coverage - - - name: Run linter - run: yarn lint - - - name: Run typescript - run: npx tsc - - - name: Deploy - uses: amondnet/vercel-action@v20 - with: - vercel-token: ${{ secrets.VERCEL_TOKEN }} - vercel-org-id: ${{ secrets.VERCEL_ORG_ID}} - vercel-project-id: ${{ secrets.VERCEL_PROJECT_ID}}