diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml new file mode 100644 index 00000000..9f5eaeb0 --- /dev/null +++ b/.github/workflows/ci.yaml @@ -0,0 +1,51 @@ +name: 🚀 Deploy +on: + push: + branches: + - main + pull_request: {} + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +permissions: + actions: write + contents: read + +jobs: + lint: + name: ⬣ ESLint + runs-on: ubuntu-latest + steps: + - name: ⬇️ Checkout repo + uses: actions/checkout@v3 + + - name: ⎔ Setup node + uses: actions/setup-node@v3 + with: + node-version-file: "next/.nvmrc" + + - name: 📥 Download deps + uses: bahmutov/npm-install@v1 + + - name: 🔬 Lint + run: npm run lint + + typecheck: + name: ʦ TypeScript + runs-on: ubuntu-latest + steps: + - name: ⬇️ Checkout repo + uses: actions/checkout@v3 + + - name: ⎔ Setup node + uses: actions/setup-node@v3 + with: + node-version-file: "next/.nvmrc" + + - name: 📥 Download deps + uses: bahmutov/npm-install@v1 + + - name: 🔎 Type check + run: npm run typecheck --if-present diff --git a/next/package.json b/next/package.json index ee2fef06..d8be7cf8 100644 --- a/next/package.json +++ b/next/package.json @@ -57,5 +57,9 @@ "ts-jest": "^29.1.1", "typescript": "5.1.6" }, + "engines": { + "node": "18", + "npm": "9" + }, "license": "MIT" }