Skip to content

docs(anoncomms): commit the initial Logos Oracle Zone RFC #3564

docs(anoncomms): commit the initial Logos Oracle Zone RFC

docs(anoncomms): commit the initial Logos Oracle Zone RFC #3564

Workflow file for this run

name: markdown-linting
on:
pull_request:
branches:
- '**'
jobs:
lint:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 20
- name: Validate Metadata And Markdown Lint
shell: bash
run: |
set -euo pipefail
BASE="${{ github.event.pull_request.base.sha }}"
HEAD="${{ github.event.pull_request.head.sha }}"
python3 scripts/validation_targets.py --base-sha "$BASE" --head-sha "$HEAD" --output .validation-targets.txt
if [ -s .validation-targets.txt ]; then
python3 scripts/validate_metadata.py --check --targets-file .validation-targets.txt
python3 scripts/gen_rfc_index.py
python3 scripts/gen_summary.py
python3 scripts/validate_generated_outputs.py --targets-file .validation-targets.txt
else
echo "No markdown validation targets."
fi
python3 scripts/lint_targets.py --base-sha "$BASE" --head-sha "$HEAD" --output .lint-targets.txt
if [ ! -s .lint-targets.txt ]; then
echo "No non-raw markdown targets."
exit 0
fi
mapfile -t files < .lint-targets.txt
npx markdownlint-cli2@0.12.1 --config .markdownlint.yaml "${files[@]}"
remark:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 20
- name: Install dependencies
run: npm install
- name: Remark Linter
shell: bash
run: |
set -euo pipefail
BASE="${{ github.event.pull_request.base.sha }}"
HEAD="${{ github.event.pull_request.head.sha }}"
python3 scripts/lint_targets.py --base-sha "$BASE" --head-sha "$HEAD" --output .lint-targets.txt
if [ ! -s .lint-targets.txt ]; then
echo "No non-raw markdown targets."
exit 0
fi
mapfile -t files < .lint-targets.txt
npx remark --frail --no-stdout --rc-path .remarkrc.mjs "${files[@]}"