Lint markdown with rumdl - [chore: move config to .config/ #19] by @o-l-a-v
#14
Workflow file for this run
This file contains hidden or 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: Lint markdown with rumdl | |
| run-name: "${{ github.workflow }} - [${{ github.event.pull_request.title }} #${{ github.event.pull_request.number }}] by @${{ github.actor }}" | |
| on: | |
| pull_request: | |
| paths: | |
| - "**.md" | |
| - ".rumdl.toml" | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| lint-markdown: | |
| name: Run rumdl | |
| permissions: | |
| contents: read | |
| pull-requests: read | |
| runs-on: ubuntu-slim | |
| steps: | |
| - name: 🛎️ GitHub checkout branch "${{ github.head_ref || github.ref_name }}" | |
| uses: actions/checkout@v6 | |
| with: | |
| persist-credentials: false | |
| - name: 🔍 Get changed files | |
| id: filter | |
| uses: dorny/paths-filter@de90cc6fb38fc0963ad72b210f1f284cd68cea36 # v3.0.2 | |
| with: | |
| filters: | | |
| markdown: | |
| - added|modified: '**.md' | |
| rumdlconf: | |
| - added|modified: '.rumdl.toml' | |
| list-files: escape | |
| - name: ⬇️ Install the latest version of uv | |
| if: steps.filter.outputs.markdown == 'true' || steps.filter.outputs.rumdlconf == 'true' | |
| uses: astral-sh/setup-uv@eac588ad8def6316056a12d4907a9d4d84ff7a3b # v7.3.0 | |
| with: | |
| cache-dependency-glob: "" | |
| enable-cache: true | |
| - name: 🔍 Lint changed markdown files with rumdl | |
| if: steps.filter.outputs.markdown == 'true' && steps.filter.outputs.rumdlconf == 'false' | |
| shell: bash | |
| run: uvx rumdl check ${{ steps.filter.outputs.markdown_files }} | |
| - name: 🔍 Lint all markdown files with rumdl when ".rumdl.toml" is updated | |
| if: steps.filter.outputs.rumdlconf == 'true' | |
| shell: bash | |
| run: uvx rumdl check . |