Skip to content

Commit

Permalink
Add playbook to run markdown linter
Browse files Browse the repository at this point in the history
Set temporary to non-voting, until final documentation review.

Change-Id: Ie1a0139625c62f52277c31c307049ff417675242
  • Loading branch information
karolinku committed Jun 20, 2024
1 parent 7da21c2 commit 9cc5edb
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 0 deletions.
10 changes: 10 additions & 0 deletions .zuul.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,21 @@
run: playbooks/build.yaml
nodeset: rdo-centos-9-stream

- job:
name: rdo-mkdocs-website-pymarkdown
parent: base
description: Run markdown linter
run: playbooks/lint_pymarkdown.yaml
nodeset: rdo-centos-9-stream
voting: false

- project:
check:
jobs:
- rdo-mkdocs-website-build
- rdo-mkdocs-website-pymarkdown
gate:
jobs:
- rdo-mkdocs-website-build
- rdo-mkdocs-website-pymarkdown

22 changes: 22 additions & 0 deletions playbooks/lint_pymarkdown.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
- hosts: all
tasks:
- name: Install required packages
become: true
package:
name:
- python3
- python3-pip
state: present

# https://github.com/jackdewinter/pymarkdown
- name: Install pymarkdown
pip:
name: pymarkdownlnt

# Ignored rules:
# MD013 Line length
# MD033 Inline HTML
- name: Run markdown linter
command: pymarkdown -d MD013 -d MD033 scan -r .
args:
chdir: "{{ ansible_user_dir }}/{{ zuul.project.src_dir }}"

0 comments on commit 9cc5edb

Please sign in to comment.