make fmt and make fmt-check cover Markdown with prettier (closes #39) #45

Merged
clawbot merged 1 commits from issue-39-prettier-markdown into next 2026-10-04 05:42:47 +02:00
Collaborator

Implements #39, on top of #47.

  • script/fmt runs go fmt, then prettier --write on **/*.md; script/fmt-check runs the gofmt -l check, then prettier --check on the same files. Apart from the Go lines and the ~/.local/go/bin PATH line that next already has, both are the sneak/prompts next copies, which take yarn from the PATH or else through nvm at the pinned node version.
  • package.json, yarn.lock and .prettierrc are byte-identical to the template copies (prettier 3.8.1, four-space indents, proseWrap: always).
  • script/bootstrap gains the template's node, yarn and yarn-install steps (nvm 0.40.3 from its release archive checked against a sha256, node 22.17.0, yarn 1.22.22) after the pinned Go install and go mod download; the Docker check stays last.
  • README.md is what make fmt made of it. Its Entrypoints line for script/bootstrap now lists the steps in the order the script takes them, and the fmt and fmt-check lines say what they cover; this issue's line leaves the TODO list.

Not visible in the diff:

  • .gitignore already carried node_modules/, so it is unchanged.
  • prettier leaves REPO_POLICIES.md as it is, so no .prettierignore was needed and the copy stays byte-identical.
  • The prettier flags in the two scripts repeat .prettierrc, as the template copies do.

Model: opus-5-5

Implements https://git.eeqj.de/sneak/keyfunc/issues/39, on top of https://git.eeqj.de/sneak/keyfunc/pulls/47. - `script/fmt` runs `go fmt`, then prettier `--write` on `**/*.md`; `script/fmt-check` runs the `gofmt -l` check, then prettier `--check` on the same files. Apart from the Go lines and the `~/.local/go/bin` `PATH` line that `next` already has, both are the `sneak/prompts` `next` copies, which take yarn from the `PATH` or else through nvm at the pinned node version. - `package.json`, `yarn.lock` and `.prettierrc` are byte-identical to the template copies (prettier `3.8.1`, four-space indents, `proseWrap: always`). - `script/bootstrap` gains the template's node, yarn and yarn-install steps (nvm `0.40.3` from its release archive checked against a sha256, node `22.17.0`, yarn `1.22.22`) after the pinned Go install and `go mod download`; the Docker check stays last. - `README.md` is what `make fmt` made of it. Its Entrypoints line for `script/bootstrap` now lists the steps in the order the script takes them, and the `fmt` and `fmt-check` lines say what they cover; this issue's line leaves the TODO list. Not visible in the diff: - `.gitignore` already carried `node_modules/`, so it is unchanged. - prettier leaves `REPO_POLICIES.md` as it is, so no `.prettierignore` was needed and the copy stays byte-identical. - The prettier flags in the two scripts repeat `.prettierrc`, as the template copies do. Model: opus-5-5
clawbot added the needs-review label 2026-10-04 03:10:33 +02:00
clawbot self-assigned this 2026-10-04 03:10:33 +02:00
Author
Collaborator
  • README.md, Entrypoints, the script/bootstrap line: it says git, make, Go, node and yarn are installed from nix, apt, brew or apk, and only node is excepted (through nvm). Yarn never comes from a system package manager: ensure_yarn installs it at the pinned 1.22.22 through corepack, or through npm when corepack is missing. Acceptable: git, make and Go from nix, apt, brew or apk; an installed node is used, otherwise a pinned one is installed through nvm; yarn at its pinned version through corepack; then the pinned prettier with yarn.

Model: opus-5-5

- `README.md`, Entrypoints, the `script/bootstrap` line: it says git, make, Go, node and yarn are installed from nix, apt, brew or apk, and only node is excepted (through nvm). Yarn never comes from a system package manager: `ensure_yarn` installs it at the pinned `1.22.22` through corepack, or through npm when corepack is missing. Acceptable: git, make and Go from nix, apt, brew or apk; an installed node is used, otherwise a pinned one is installed through nvm; yarn at its pinned version through corepack; then the pinned prettier with yarn. Model: opus-5-5
clawbot added needs-rework and removed needs-review labels 2026-10-04 03:55:27 +02:00
clawbot added 1 commit 2026-10-04 05:10:28 +02:00
script/fmt now runs go fmt and then prettier --write on every Markdown
file; script/fmt-check runs the gofmt check and then prettier --check.
prettier is pinned in package.json and yarn.lock and configured in
.prettierrc with four-space indents and prose wrapped at 80 columns,
all copied from the sneak/prompts templates. After Go and the Go
modules, script/bootstrap uses an installed node or else a pinned one
through a hash-verified nvm archive, then an installed yarn or else a
pinned one, then the yarn dependencies. README.md is reformatted by
make fmt, and its Entrypoints section says what fmt, fmt-check and
bootstrap now do.

Model: opus-5-5
clawbot force-pushed issue-39-prettier-markdown from a2cc08cae9 to 1ff02f252d 2026-10-04 05:10:28 +02:00 Compare
clawbot added needs-review and removed needs-rework labels 2026-10-04 05:17:06 +02:00
Author
Collaborator

Rebased onto next, keeping the pinned Go install from #47 and adding the node, yarn and prettier steps after it. The Entrypoints line for script/bootstrap now lists each step in the script's order, with an installed node or yarn used as it is, and the fmt-check line adds prettier to what both scripts need from bootstrap.

Model: opus-5-5

Rebased onto `next`, keeping the pinned Go install from https://git.eeqj.de/sneak/keyfunc/pulls/47 and adding the node, yarn and prettier steps after it. The Entrypoints line for `script/bootstrap` now lists each step in the script's order, with an installed node or yarn used as it is, and the `fmt-check` line adds prettier to what both scripts need from `bootstrap`. Model: opus-5-5
Author
Collaborator

Review passed.

Model: opus-5-5

Review passed. Model: opus-5-5
clawbot merged commit 1ddc2c747a into next 2026-10-04 05:42:47 +02:00
clawbot deleted branch issue-39-prettier-markdown 2026-10-04 05:42:47 +02:00
Sign in to join this conversation.