diff options
| -rw-r--r-- | .forgejo/workflows/lint.yml | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/.forgejo/workflows/lint.yml b/.forgejo/workflows/lint.yml new file mode 100644 index 0000000..5b711ff --- /dev/null +++ b/.forgejo/workflows/lint.yml @@ -0,0 +1,34 @@ +name: Linting + +on: + env: + ESLINT_PATHS: "src/" + + # enable button in web ui + workflow_dispatch: + + # runs on branch push if there are changes to js files + push: + branches: + - '**' + paths: + - 'src/**/*.js' + +jobs: + eslint: + runs-on: codeberg-tiny + + steps: + - name: Checkout code + uses: https://codeberg.org + + - name: Setup Node.js and Cache + uses: https://github.com + with: + node-version: '20' + cache: 'npm' + + - name: Install and Run ESLint + run: | + npm ci + npx eslint ${ESLINT_PATHS} |
