diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 41cd93376df..0ec94a14d8f 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -84,6 +84,24 @@ jobs: - name: Install Node dependencies run: pnpm install --frozen-lockfile + - name: Cache ESLint + uses: actions/cache@0057852bfaa89a56745cba8c7296529d2fc39830 # v4.3.0 + with: + path: .eslintcache + key: ${{ runner.os }}-eslint-${{ hashFiles('eslint.config.mjs') }}-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-eslint-${{ hashFiles('eslint.config.mjs') }}- + ${{ runner.os }}-eslint- + + - name: Cache Prettier + uses: actions/cache@0057852bfaa89a56745cba8c7296529d2fc39830 # v4.3.0 + with: + path: node_modules/.cache/prettier + key: ${{ runner.os }}-prettier-${{ hashFiles('.prettierrc.json') }}-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-prettier-${{ hashFiles('.prettierrc.json') }}- + ${{ runner.os }}-prettier- + - name: Lint unowned dependencies run: pnpm run lint:dep-ownership diff --git a/package.json b/package.json index 9a036f16cd1..dbf50fd6b42 100644 --- a/package.json +++ b/package.json @@ -14,7 +14,7 @@ "homepage": "https://bitwarden.com", "scripts": { "prepare": "husky", - "lint": "eslint . --cache --cache-strategy content && prettier --check .", + "lint": "eslint . --cache --cache-strategy content && prettier --cache --check .", "lint:fix": "eslint . --cache --cache-strategy content --fix", "lint:clear": "rimraf .eslintcache", "prettier": "prettier --cache --write .",