Handoff — 2026-09-01 — Dockerfile, compose, YAML and XML colouring (ticket 8)
State
Ticket 8 is implemented and verified, in all three repositories, on the branch feature/more-syntaxes. Nothing is committed.
turbo-core now colours eight languages. Three scanners were added:
syntax/yaml.go,syntax/yaml_block.go,syntax/yaml_key.go— one YAML scanner serving compose files, Kubernetes manifests and CI workflows alike.syntax/dockerfile.go— instructions matched in any case,--flags,$VAR/${VAR}, the trailing\, and the parser directives as comments.syntax/xml.go— its own scanner rather than HTML's, because of CDATA.
Definition gained Filenames []string, and LanguageOf a name step between the extension and the shebang. That is the only change to an existing API, and it is additive.
Suite green in all three; quality gate PASS 0/0/0 in all three (turbo-core complexity 1718, turbo-go 37, turbo-rust 98). Documentation is complete in EN and FR in all three, and syntax/README.md is in sync.
In flight
Nothing half-done. The work stops at the commit.
Next steps
- Review and commit on
feature/more-syntaxesin all three repositories, merge tomain. - Release turbo-core v0.2.0 —
Definition.Filenamesand the three newLanguageconstants are new public API, so it is a minor bump:TAG=v0.2.0 ./01-release.tag.sh TAG=v0.2.0 ./02-release.publish.sh - In each editor,
go mod tidyto write the v0.2.0 checksum intogo.sum, thenmake check. Until step 2 is done, neither editor builds — theirgo.modalready requires v0.2.0 andgo.sumhas no entry for it. The error names it exactly:missing go.sum entry for module providing package codeberg.org/turbo-editors/turbo-core/app.
Open questions / blockers
- Only the release. Nothing is waiting on a decision.
Watch out for
- A YAML colon is a separator only when a space or the end of the line follows it. Anybody "simplifying" that rule will put every
image: nginx:1.27and every URL back into three colours. There is a test that walks every column of the span; do not weaken it into a spot check. - The Dockerfile scanner keeps
:in a word for the same reason —golang:1.26-alpineis one thing.dockerfileWordRunesis where that lives. - A YAML block scalar has no closing delimiter. Its extent is the indentation the first content line set, and a blank line inside one stays inside it. Ending at the first blank line looks reasonable and cuts a shell script in a CI file in half.
- XML carries which construct is open, not a flag. A single boolean closes a CDATA section on a
-->that happens to be inside it. - An empty stem must match nothing.
.gitignoreis all extension; if the stem rule accepts an empty stem it becomes a wildcard and every dotfile becomes a Dockerfile. - The quality gate found four smells in the first version of these scanners — three
qlty:boolean-logicfrom inline rune comparisons, oneqlty:file-complexityonyaml.go. The fix was named constants and three files; keep new scanners in that shape rather than one long switch. release.envandturbo-core.token.envhold live Codeberg tokens and are covered by*.envin.gitignore. Keep it that way.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 |
|