From 70a2f849be4ebf24879fe6626d3f12055ec06d2b Mon Sep 17 00:00:00 2001 From: David Anson Date: Sat, 23 Jul 2022 13:36:46 -0700 Subject: [PATCH] Add examples for command=fix/config to README.md, tweak test name. --- .github/workflows/test.yml | 2 +- README.md | 20 ++++++++++++++++++++ 2 files changed, 21 insertions(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 49941b4..79294cd 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -58,7 +58,7 @@ jobs: config/test.markdownlint.jsonc test/* command-config-invalid: - name: Command = config (invalid, fails) + name: Command = config (invalid configuration file, fails) runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 diff --git a/README.md b/README.md index f10022d..219050f 100644 --- a/README.md +++ b/README.md @@ -67,6 +67,26 @@ To lint specific Markdown files in a project: docs/*.md ``` +To fix supported issues when linting: + +```yaml +- uses: DavidAnson/markdownlint-cli2-action@v5 + with: + command: fix + globs: '**/*.md' +``` + +To specify a custom configuration file: + +```yaml +- uses: DavidAnson/markdownlint-cli2-action@v5 + with: + command: config + globs: | + config/custom.markdownlint.jsonc + **/*.md +``` + To prevent linting issues from failing the workflow run: ```yaml