Skip to content

Commit

Permalink
chore: update markdownlint-cli2 config
Browse files Browse the repository at this point in the history
  • Loading branch information
boneskull committed Dec 13, 2023
1 parent 4b72c58 commit ed2531a
Show file tree
Hide file tree
Showing 6 changed files with 275 additions and 459 deletions.
16 changes: 10 additions & 6 deletions .lintstagedrc.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,17 @@
module.exports = {
'*.{js,ts}': ['eslint --fix', 'prettier --write'],
'*.md': ['markdownlint-cli2-fix', 'prettier --write'],
'!(_*).md': ['markdownlint-cli2-fix', 'prettier --write'],
'*.ya?ml': ['prettier --write'],
/**
* This _should_ match if the options change, the rules change, the schema-generating script changes,
* or we've had dependency changes.
* This _should_ match if the options change, the rules change, the
* schema-generating script changes, or we've had dependency changes.
*
* @returns Command to update schema
*/
'(./src/rules/**/*.ts|src/options.ts|./scripts/generate-schema.ts|./package.json|./package-lock.json)':
() => ['npm run update-schema'],
'./package.json': ['prettier --write'],
'(./packages/plugin-default/src/**/*.ts|packages/midnight-smoker/src/options.ts|./packages/midnight-smoker/scripts/generate-schema.ts|package.json|package-lock.json)':
() => [
'npm run update-schema',
'git add -A packages/midnight-smoker/schema/midnight-smoker.schema.json',
],
'*.json': ['prettier --write'],
};
22 changes: 22 additions & 0 deletions .markdownlint-cli2.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
config:
ul-style:
style: dash
ul-indent:
indent: 2
commands-show-output: false
no-bare-urls: false
line-length: false
no-emphasis-as-header: false
no-duplicate-header: false
header-increment: false
no-blanks-blockquote: false
ignores:
- '**/node_modules/**'
- 'docs/README.md' # generated
- 'docs/**/_*.md' # special
- '**/CHANGELOG.md' # generated
outputFormatters:
- - 'markdownlint-cli2-formatter-pretty'
- appendLink: true
showFound: true
noProgress: false
11 changes: 0 additions & 11 deletions .markdownlint.yml

This file was deleted.

58 changes: 58 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
"lint:commit": "commitlint",
"lint:eslint": "eslint .",
"lint:fix": "eslint . --fix",
"lint:md": "markdownlint-cli2 \"README.md\" \"packages/*/README.md\" \"docs/**/*.md\" \"!docs/README.md\"",
"lint:md": "markdownlint-cli2 \"**/*.md\"",
"lint:staged": "lint-staged",
"prepare": "run-p husky-install rebuild",
"pretest:e2e": "run-s build",
Expand Down Expand Up @@ -64,6 +64,7 @@
"husky": "8.0.3",
"lint-staged": "14.0.1",
"markdownlint-cli2": "0.11.0",
"markdownlint-cli2-formatter-pretty": "0.0.5",
"mocha": "10.2.0",
"npm-run-all": "4.1.5",
"prettier": "3.1.1",
Expand Down
Loading

0 comments on commit ed2531a

Please sign in to comment.