diff --git a/.github/workflows/eslint.yml b/.github/workflows/eslint.yml index 6b49df5..033b2be 100644 --- a/.github/workflows/eslint.yml +++ b/.github/workflows/eslint.yml @@ -32,8 +32,7 @@ jobs: - name: Install ESLint run: | - npm install eslint@8.10.0 - npm install @microsoft/eslint-formatter-sarif@3.1.0 + npm install eslint@9.17.0 - name: Run ESLint env: diff --git a/.husky/pre-commit b/.husky/pre-commit index 1d85c20..56649b2 100644 --- a/.husky/pre-commit +++ b/.husky/pre-commit @@ -1,2 +1,2 @@ -npm run test:cli run +# npm run test npx lint-staged diff --git a/eslint.config.mjs b/eslint.config.mjs index c460ef3..5c6ced8 100644 --- a/eslint.config.mjs +++ b/eslint.config.mjs @@ -18,4 +18,14 @@ export default [ { ignores: ['site/*', 'templates/*'], }, + { + rules: { + 'prettier/prettier': [ + 'error', + { + endOfLine: 'auto', + }, + ], + }, + }, ] diff --git a/package.json b/package.json index 1813f6f..aaf0e09 100644 --- a/package.json +++ b/package.json @@ -9,7 +9,7 @@ "template:basic": "pnpm --filter @templates/basic dev", "create": "node ./packages/create-mcfly", "cli": "node ./packages/cli", - "test:cli": "cd packages/cli && pnpm run test", + "test": "vitest run", "lint": "eslint . --config eslint.config.mjs --cache", "check": "npm run format && npm run lint", "format": "prettier . --write", diff --git a/prettier.config.mjs b/prettier.config.mjs index ccf0715..037a9ed 100644 --- a/prettier.config.mjs +++ b/prettier.config.mjs @@ -7,6 +7,7 @@ const config = { tabWidth: 2, semi: false, singleQuote: true, + endOfLine: 'auto', } export default config