docs: Markdown linting #2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Pymarkdownlnt | |
# Runs the workflow on the below events: | |
# 1. on pull request raised to trunk branch. | |
# 2. on push event to trunk branch. | |
on: | |
push: | |
branches: | |
- trunk | |
pull_request: | |
branches: | |
- trunk | |
permissions: # added using https://github.com/step-security/secure-workflows | |
contents: read | |
jobs: | |
lint-markdown: | |
runs-on: ubuntu-latest | |
name: Lint Markdown | |
steps: | |
- name: Set up Python | |
uses: actions/setup-python@65d7f2d534ac1bc67fcd62888c5f4f3d2cb2b236 # v4.7.1 | |
with: | |
python-version: 3.9 #install the python needed | |
- name: checkout repo content | |
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 | |
- name: Install and run linter | |
run: |- | |
python3 -m pip install --require-hashes -r tools/requirements.txt | |
pymarkdownlnt -d MD013,MD024 scan */*.md |