chore: update eslint action & eslint-prettier config for endOfLine
This commit is contained in:
parent
c0c2ded47c
commit
a36d622634
5 changed files with 14 additions and 4 deletions
3
.github/workflows/eslint.yml
vendored
3
.github/workflows/eslint.yml
vendored
|
@ -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:
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
npm run test:cli run
|
||||
# npm run test
|
||||
npx lint-staged
|
||||
|
|
|
@ -18,4 +18,14 @@ export default [
|
|||
{
|
||||
ignores: ['site/*', 'templates/*'],
|
||||
},
|
||||
{
|
||||
rules: {
|
||||
'prettier/prettier': [
|
||||
'error',
|
||||
{
|
||||
endOfLine: 'auto',
|
||||
},
|
||||
],
|
||||
},
|
||||
},
|
||||
]
|
||||
|
|
|
@ -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",
|
||||
|
|
|
@ -7,6 +7,7 @@ const config = {
|
|||
tabWidth: 2,
|
||||
semi: false,
|
||||
singleQuote: true,
|
||||
endOfLine: 'auto',
|
||||
}
|
||||
|
||||
export default config
|
||||
|
|
Loading…
Reference in a new issue