From 493ae2da7b12e5107e7e13a9ba2874229229002b Mon Sep 17 00:00:00 2001 From: Jason Madigan Date: Fri, 18 Oct 2024 13:58:34 +0100 Subject: [PATCH] Create lint.yaml --- .github/workflows/lint.yaml | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 .github/workflows/lint.yaml diff --git a/.github/workflows/lint.yaml b/.github/workflows/lint.yaml new file mode 100644 index 0000000..cb718af --- /dev/null +++ b/.github/workflows/lint.yaml @@ -0,0 +1,35 @@ +name: Lint Check + +on: + # pull_request: + # branches: + # - '**' + workflow_dispatch: + +jobs: + lint: + runs-on: ubuntu-latest + + steps: + - name: Checkout code + uses: actions/checkout@v3 + + - name: Set up Node.js + uses: actions/setup-node@v3 + with: + node-version: '22' + + - name: Install dependencies + run: yarn install + + - name: Run lint + run: yarn lint + + - name: Check for changes + run: | + if [[ $(git status --porcelain) ]]; then + echo "Linting caused changes, failing the build." + exit 1 + else + echo "No changes detected." + fi