Repository navigation
docs(site): add configuration tab to locale - #181
Merged
Merged
Conversation
Chirpy takes the browser title for a tab page from the tabs map in _data/locales/en.yml, keyed by the lowercased page title. The map had no entry for the Configuration tab added in #178, so the page rendered with an empty <title>.
This override drops the `| default:` that the theme's own sidebar and page heading both carry, so a tab missing from the locale map renders an empty <title> rather than an imperfect one. That is what happened to the Configuration tab. Matching upstream makes the next one self-healing.
ryanlewis
added a commit
that referenced
this pull request
Sep 5, 2026
## What changed "A missing file is not an error" describes the config file by what does not go wrong. "The file is optional" says what it is. Replaced everywhere it appeared. **User-facing text:** - `docs/_tabs/configuration.md` — the callout under the lookup table: > **The config file is optional.** Without one, `things` runs on its built-in defaults. The same applies to a path you name yourself; run `things config path` to see which file is in use and whether it exists. - `README.md` — "The file is optional — without one, `things` runs on its built-in defaults." - `internal/config/config.go`, the `config init` template header: ``` # Read from $XDG_CONFIG_HOME/things-cli/config.toml, or # ~/.config/things-cli/config.toml. Override with --config PATH or # $THINGS_CLI_CONFIG. The file is optional; without it, things runs on # its built-in defaults. ``` Wrapped over two lines to stay inside the 72 columns the rest of the header uses; the suggested single line was 73. **Doc comments**, so the code reads the same way as the docs: the comments on `config.File` and `config.Load` now say the file is optional rather than that its absence is not an error. ## The template and the page The `toml` block on the configuration page has to stay byte-identical to `Template()` — `TestDocsPageQuotesTheTemplate` enforces it — so both changed together. The page block was regenerated by running `things config init` and pasting the result, not hand-edited, so the two cannot have drifted in the edit. ## Also checked `docs/_tabs/commands.md` and `internal/skill/SKILL.md` do not carry the phrase. Neither describes the missing-file case at all: `commands.md` links to the configuration page for it, and SKILL.md says "the user **may** have a TOML file", which already reads as optional. Left both alone. `grep -rn "not an error"` across `README.md`, `docs/`, `internal/` and `cmd/` now returns nothing. ## How tested `make test` (`go test -race ./...`) and `make lint` clean, including the three docs-sync tests from #178 — the template check is what proves the page and the binary still agree. Not verified by building the site, for the reasons in #178 and #181: no PR-time docs check, and no local Ruby new enough for `jekyll-theme-chirpy ~> 7.2`. The page edits are prose inside an existing callout and an existing fenced block, with no structural change.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changed
Two commits, separable.
docs(site): add configuration tab to locale— the fix. Chirpy takes a tab page's browser title from thetabs:map indocs/_data/locales/en.yml, keyed by the lowercased page title. The map listedinstallandcommandsbut notconfiguration, so the tab added in #178 rendered with an empty<title>. One line:configuration: Configuration.docs(site): fall back to the page title when a tab has no locale entry— optional, drop it if you would rather not touch the override.docs/_includes/head.html:63reads the locale map with nodefault:filter, which is why a missing key produced an empty title rather than an imperfect one. The theme's own equivalents both carry the fallback, so the override looks like it diverged by accident:docs/_includes/head.html(this repo)site.data.locales[include.lang].tabs[tab_key]_includes/sidebar.html... tabs.[tab_name] | default: tab.title | upcase_layouts/page.html... tabs[tab_key] | default: page.titleAdding
| default: page.titlematches upstream and makes the next tab self-healing.What else depends on the locale
Nothing else on the page was broken. The sidebar label and the
<h1>both go through the theme, and both already fall back to the front-matter title, so they rendered "CONFIGURATION" and "Configuration" correctly all along — the empty<title>was the only symptom.jekyll-seo-tagusespage.titledirectly and is unaffected.Checked every tab against the map:
about,commands,configurationandinstallall now have a key matching their lowercased title.How verified
Not by building the site — there is no PR-time docs check (
pages.ymlruns only on push tomain), and a localbundle exec jekyll buildis not possible here: system Ruby is 2.6.10 andjekyll-theme-chirpy ~> 7.2needs 3.1+.Instead:
en.ymlparses as YAML with the expectedtabsmap, everydocs/_tabs/*.mdfront-matter title lowercases to a key present in it, and the two theme templates were read at thev7.2.4tag to confirm where the fallbacks are and thathead.htmlis the only place without one.make testandmake lintare clean, though neither touches the site.Possible follow-up
A tab whose locale key is missing is now cosmetic rather than broken, so nothing further is needed. If you would rather it were caught outright, a check that every
docs/_tabs/*.mdtitle has a key inen.ymlwould do it — it is the same shape as the docs-sync tests from #178, though it would need a home, since nothing underdocs/is Go.