From 3c25de8c57f6fc5e74ab65d3c26fca9b0580fe88 Mon Sep 17 00:00:00 2001 From: Nick Schonning Date: Tue, 23 Nov 2021 10:47:43 -0500 Subject: [PATCH] style: run prettier during lint (#724) --- .github/dependabot.yml | 4 ++-- .github/workflows/labeler.yml | 2 +- .github/workflows/production.yml | 3 +-- .github/workflows/test-release.yml | 1 - package.json | 4 ++-- 5 files changed, 6 insertions(+), 8 deletions(-) diff --git a/.github/dependabot.yml b/.github/dependabot.yml index c5af001ac..a8afdef11 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -1,11 +1,11 @@ version: 2 updates: - package-ecosystem: npm - directory: "/" + directory: '/' schedule: interval: weekly versioning-strategy: increase - package-ecosystem: github-actions - directory: "/" + directory: '/' schedule: interval: weekly diff --git a/.github/workflows/labeler.yml b/.github/workflows/labeler.yml index ca333641f..c2769f0c9 100644 --- a/.github/workflows/labeler.yml +++ b/.github/workflows/labeler.yml @@ -9,4 +9,4 @@ jobs: steps: - uses: actions/labeler@v3.0.2 with: - repo-token: "${{ secrets.GITHUB_TOKEN }}" + repo-token: '${{ secrets.GITHUB_TOKEN }}' diff --git a/.github/workflows/production.yml b/.github/workflows/production.yml index 2fa03017a..f87ea1a15 100644 --- a/.github/workflows/production.yml +++ b/.github/workflows/production.yml @@ -62,8 +62,7 @@ jobs: file: ./coverage/lcov.info release: - if: - ${{ github.repository == 'htmlhint/HTMLHint' && + if: ${{ github.repository == 'htmlhint/HTMLHint' && contains('refs/heads/master,refs/heads/beta,refs/heads/next,refs/heads/alpha', github.ref) && github.event_name == 'push' }} runs-on: ubuntu-latest diff --git a/.github/workflows/test-release.yml b/.github/workflows/test-release.yml index 776d30df1..b1d2aa086 100644 --- a/.github/workflows/test-release.yml +++ b/.github/workflows/test-release.yml @@ -56,4 +56,3 @@ jobs: env: GITHUB_TOKEN: ${{ secrets.GH_TOKEN }} NPM_TOKEN: ${{ secrets.NPM_TOKEN }} - diff --git a/package.json b/package.json index 009248869..5d22ec62f 100644 --- a/package.json +++ b/package.json @@ -30,8 +30,8 @@ "build:rollup": "npm run build:min && npm run build:unmin", "build:min": "rollup -c --environment NODE_ENV:production --file dist/htmlhint.min.js", "build:unmin": "rollup -c", - "lint": "eslint . --ext .js,.ts --max-warnings 0", - "lint:fix": "eslint --fix . --ext .js,.ts --max-warnings 0", + "lint": "prettier -c . && eslint . --ext .js,.ts --max-warnings 0", + "lint:fix": "npm run prettier && npm run lint -- --fix", "test:coverage": "nyc npm run test" }, "husky": {