.agents/skills/project-knowledge/references/codebase.md
.github/workflows/vale.yml) explicitly lints AGENTS.md, .github/copilot-instructions.md,
and .agents/skills, while markdownlint-cli2 skips dot-directories entirely - its globs never
match .agents/ or .github/, even when passed explicit paths. Lint skill docs with Vale
before pushing; for markdownlint, copy them to a non-dot directory alongside
.markdownlint-cli2.yaml..vale.ini, each with a comment.src/, not the repo root - run all go commands from there.go test -race is NOT supported. Concurrency-sensitive changes
must rely on CI (amd64) for race detection.src/template/bench_test.go,
src/terminal/bench_test.go, and src/prompt/bench_test.go; compare runs with benchstat.template.Init resets the parsed-template cache - a macro benchmark that calls it per iteration
measures the cold-parse path, not steady state.src/shell/scripts/ is embedded at build time (go:embed). After editing a
script, rebuild the binary before testing; oh-my-posh init <shell> --print shows the generated
output and is the fastest way to inspect what a user actually sources.src/shell/<shell>.go - a script function is dead code unless the feature switch emits its
activation line.Execute runs in bare goroutines with no recover (src/prompt/segments.go), and
template rendering re-panics runtime errors. Any panic there kills the whole process - the user
sees a completely blank prompt. So when a user reports a blank prompt: find the panic.segments.Base.env/options are unexported and
MUST survive a cache restore: overlay the restored data onto the writer initialized by
MapSegmentWithWriter, never replace the writer.--save-cache flag (print/stream commands);
without it, stores never write on close. Redirect the location with OMP_CACHE_DIR.oh-my-posh debug command (grep for
restored segment from cache / setting entry). POSH_TRACE=1 and stderr show nothing for
print commands.store.go:init EOF error on first
read."streaming": <ms> config key. That value is ALSO each
segment's pending-timeout and overwrites segment-level timeout.stream always emits the transient prompt as a \x1e-prefixed NUL record (initial + refreshed
once all segments resolve); serve records are <id>\x1f<payload>\0.if X != nil return) pin first-render state
in a daemon. template.Cache did exactly that (pinned PWD/Folder/Code/Jobs) - fixed with
template.ResetCache() per render in startRenderCycle (flag-based rebuild; never nil the
global, abandoned segment goroutines may still read it). Audit for this pattern when extending
serve.config.Get prefers the session gob cache over POSH_THEME.renderComplete) - blocking clients (Clink) rely on this.