From f30e8dcd1b2ddaf4c787e9e2806e2b0b159d9aac Mon Sep 17 00:00:00 2001 From: Kevin Moore Date: Sat, 12 Sep 2026 21:06:12 +0000 Subject: [PATCH 1/2] ci: add merge-blocking markdown format check Part of standardizing markdown formatting across the personal repos. This repo's markdown is already byte-identical to the standard, so this PR adds configuration only and changes no markdown whatsoever. - `.prettierrc.json` encodes the `mdf` standard (prose wrap at 80). Scoped to `**/*.md` via `overrides` so a stray `prettier --write .` cannot touch `pubspec.yaml` or workflow YAML. `embeddedLanguageFormatting: off` stops prettier rewriting fenced json/yaml examples. - `.prettierignore` excludes generated dartdoc output, which is untracked but would otherwise be caught by prettier's filesystem glob and make local runs disagree with CI. - `markdown.yml` pins prettier to the same version `mise` installs locally, and pins actions by SHA. The job is named `markdown` because the job ID becomes the check-run context that the branch ruleset matches on. The check is added to the ruleset only after this lands, so no in-flight PR is stranded by a required context that no workflow yet produces. No version bump or changelog entry: this changes CI configuration only and nothing in any published package. --- .github/workflows/markdown.yml | 22 ++++++++++++++++++++++ .prettierignore | 4 ++++ .prettierrc.json | 12 ++++++++++++ 3 files changed, 38 insertions(+) create mode 100644 .github/workflows/markdown.yml create mode 100644 .prettierignore create mode 100644 .prettierrc.json diff --git a/.github/workflows/markdown.yml b/.github/workflows/markdown.yml new file mode 100644 index 0000000..d90a726 --- /dev/null +++ b/.github/workflows/markdown.yml @@ -0,0 +1,22 @@ +name: Markdown + +# Runs unconditionally on every PR to main -- deliberately NO `paths:` filter. +# This job is a required status check, and a path-filtered required check never +# reports on PRs that touch no markdown, blocking them forever at +# "Expected - waiting for status to be reported". + +on: + pull_request: + branches: [main] + workflow_dispatch: + +jobs: + # Job ID is the check-run context name the branch ruleset matches on. + markdown: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 + - uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0 + with: + node-version: "24" + - run: npx --yes prettier@3.9.6 --check "**/*.md" diff --git a/.prettierignore b/.prettierignore new file mode 100644 index 0000000..c88c93c --- /dev/null +++ b/.prettierignore @@ -0,0 +1,4 @@ +# Generated dartdoc output. Untracked locally, but `mdf` and prettier's `**/*.md` +# glob walk the filesystem rather than the git index, so without this an +# existing `dart doc` build makes local runs disagree with CI. +doc/api/** diff --git a/.prettierrc.json b/.prettierrc.json new file mode 100644 index 0000000..128542e --- /dev/null +++ b/.prettierrc.json @@ -0,0 +1,12 @@ +{ + "overrides": [ + { + "files": ["**/*.md"], + "options": { + "proseWrap": "always", + "printWidth": 80, + "embeddedLanguageFormatting": "off" + } + } + ] +} From bd3fc61d957879a9f78e4a69426df8143845f935 Mon Sep 17 00:00:00 2001 From: Kevin Moore Date: Sat, 12 Sep 2026 21:18:01 +0000 Subject: [PATCH 2/2] chore: drop .prettierignore The doc/api exclusion was speculative -- dartdoc output is never generated into these repos, so the file only added noise to the canonical set. --- .prettierignore | 4 ---- 1 file changed, 4 deletions(-) delete mode 100644 .prettierignore diff --git a/.prettierignore b/.prettierignore deleted file mode 100644 index c88c93c..0000000 --- a/.prettierignore +++ /dev/null @@ -1,4 +0,0 @@ -# Generated dartdoc output. Untracked locally, but `mdf` and prettier's `**/*.md` -# glob walk the filesystem rather than the git index, so without this an -# existing `dart doc` build makes local runs disagree with CI. -doc/api/**