diff --git a/.github/workflows/lint.yaml b/.github/workflows/lint.yaml new file mode 100644 index 0000000..98f0e27 --- /dev/null +++ b/.github/workflows/lint.yaml @@ -0,0 +1,38 @@ +name: Lint + +on: + pull_request: + branches: [main] + +jobs: + lint: + runs-on: ubuntu-latest + strategy: + matrix: + node-version: [18] + + steps: + - name: Cancel Previous Runs + uses: styfle/cancel-workflow-action@0.12.0 + with: + access_token: ${{ github.token }} + + - name: Checkout Master + uses: actions/checkout@v4 + + - uses: pnpm/action-setup@v2.4.0 + + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v3 + with: + node-version: ${{ matrix.node-version }} + cache: pnpm + + - name: Install Dependencies + run: pnpm i + + - name: Lint Prettier + run: pnpm lint:prettier + + - name: Lint ESLint + run: pnpm lint diff --git a/package.json b/package.json index 3d53852..79d3bef 100644 --- a/package.json +++ b/package.json @@ -2,6 +2,7 @@ "name": "faast-rt-docs", "version": "0.0.1", "description": "The official documentation repository for Faast", + "packageManager": "pnpm@8.8.0", "scripts": { "dev": "next dev", "build": "next build",