diff --git a/.ci/Makefile b/.ci/Makefile index ed7f0f04..3831931e 100644 --- a/.ci/Makefile +++ b/.ci/Makefile @@ -12,9 +12,6 @@ install: # https://pnpm.io/cli/install#--frozen-lockfile pnpm install --frozen-lockfile -lint-code: - pnpm run lint:code --max-warnings 0 - lint-gh-actions: ationlint diff --git a/.github/workflows/reusable-lint.yml b/.github/workflows/reusable-lint.yml index bce589e5..98036bd3 100644 --- a/.github/workflows/reusable-lint.yml +++ b/.github/workflows/reusable-lint.yml @@ -13,7 +13,7 @@ jobs: - name: Setup uses: ./.github/actions/setup - name: Run linter - run: cd .ci && make lint-code + run: pnpm run lint:code github-actions: name: GitHub Actions diff --git a/.lintstagedrc.json b/.lintstagedrc.json index c9033b1a..ba9ce4a5 100644 --- a/.lintstagedrc.json +++ b/.lintstagedrc.json @@ -1,8 +1,8 @@ { - "*": ["pnpm run format"], - "projects/ngx-meta/src/**/*.ts": ["ng-lint-staged lint:code --fix --"], - "projects/ngx-meta/example-apps/**/*.ts": [ - "ng-lint-staged lint:code --fix --" + "!(*.ts)": ["pnpm run format"], + "projects/ngx-meta/{src,e2e,example-apps,schematics}/**/*.ts": [ + "ng-lint-staged lint:code --fix --", + "pnpm run format" ], ".github/**/*.{yml,yaml}": ["pnpm run lint:gh-actions"] } diff --git a/angular.json b/angular.json index 62924007..b7964595 100644 --- a/angular.json +++ b/angular.json @@ -39,10 +39,11 @@ "lintFilePatterns": [ "projects/ngx-meta/src/**/*.ts", "projects/ngx-meta/src/**/*.html", + "projects/ngx-meta/e2e/**/*.ts", "projects/ngx-meta/example-apps/**/*.ts", - "projects/ngx-meta/e2e/**/*.cy.ts", "projects/ngx-meta/schematics/**/*.ts" - ] + ], + "maxWarnings": 0 } } } diff --git a/package.json b/package.json index ceaa972d..041ac900 100644 --- a/package.json +++ b/package.json @@ -31,7 +31,6 @@ "prepare": "husky", "commitlint-edit-msg": "commitlint --verbose --edit", "commitlint-last": "commitlint --verbose --from HEAD~1", - "ng-lint-staged": "ng-lint-staged lint --max-warnings 0 --fix --", "cache-clean": "ng cache clean", "commit": "pnpx @commitlint/prompt-cli", "validate-codecov-yml": "curl -X POST --data-binary @codecov.yml https://codecov.io/validate",