From aaf87b84f58beaa606b4dd8f175b1bbcb85d9faf Mon Sep 17 00:00:00 2001 From: Ward Van Heddeghem Date: Tue, 18 Jun 2024 20:42:27 +0200 Subject: [PATCH] Add markdown linting GH Action --- .github/workflows/lint-markdown.yml | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 .github/workflows/lint-markdown.yml diff --git a/.github/workflows/lint-markdown.yml b/.github/workflows/lint-markdown.yml new file mode 100644 index 0000000..804189d --- /dev/null +++ b/.github/workflows/lint-markdown.yml @@ -0,0 +1,26 @@ +name: Lint markdown files +# From: https://github.com/marketplace/actions/markdown-linting-action +# Overview of markdownlint: https://github.com/DavidAnson/markdownlint +# VSC plugin: https://marketplace.visualstudio.com/items?itemName=DavidAnson.vscode-markdownlint + +on: + push: + branches: [ "main", "develop" ] + +permissions: + contents: read + +jobs: + lint-changelog: + name: Lint markdown files + runs-on: ubuntu-latest + steps: + - name: Check out code + uses: actions/checkout@v4 + - name: Lint markdown + uses: docker://avtodev/markdown-lint:v1 # fastest way + with: + # rules: ".changelog-rules.js" + # config: ".markdownlint.yml" + args: "./README.md ./changelog.md" + # ignore: './one_file.md ./another_file.md' # multiple files must be separated with single space