From ea612a618c03f1ba20bd9b4caff9f645a367dbbd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20=C3=85berg?= Date: Tue, 16 Dec 2025 00:57:27 +0100 Subject: [PATCH] Try running with eslint and prettier caching --- .github/workflows/lint.yml | 18 ++++++++++++++++++ package.json | 2 +- 2 files changed, 19 insertions(+), 1 deletion(-) 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 .",