From 08e7ced5287e1a61a043b64e66ac5fe67cffd99d Mon Sep 17 00:00:00 2001 From: Felix Lu Date: Thu, 21 Nov 2024 13:22:50 +0800 Subject: [PATCH] ci: use markdownlint-cli2 config file for better ignore patterns --- .github/workflows/ci.yml | 2 +- .markdownlint-cli2.jsonc | 11 +++++++++++ .markdownlint.json | 8 -------- 3 files changed, 12 insertions(+), 9 deletions(-) create mode 100644 .markdownlint-cli2.jsonc delete mode 100644 .markdownlint.json diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 07ef4f0f..44e27e87 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -23,7 +23,7 @@ jobs: id: markdownlint run: | bun install markdownlint-cli2 - bunx --bun markdownlint-cli2 "**/*.md" --fix + bunx --bun markdownlint-cli2 --config .markdownlint-cli2.jsonc --fix - name: Commit fixes run: | if [[ -n $(git status --porcelain) ]]; then diff --git a/.markdownlint-cli2.jsonc b/.markdownlint-cli2.jsonc new file mode 100644 index 00000000..ed6ed296 --- /dev/null +++ b/.markdownlint-cli2.jsonc @@ -0,0 +1,11 @@ +{ + "config": { + "default": true, + "MD013": false, + "MD033": false, + "MD041": false, + "MD032": true + }, + "ignores": ["node_modules/**", "dist/**", ".git/**"], + "globs": ["**/*.md"] +} diff --git a/.markdownlint.json b/.markdownlint.json deleted file mode 100644 index 458fba52..00000000 --- a/.markdownlint.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "default": true, - "MD013": false, - "MD033": false, - "MD041": false, - "MD032": true, - "line-length": false - } \ No newline at end of file