Skip to content

v0.5.0

Choose a tag to compare

@github-actions github-actions released this 21 Aug 18:46
· 56 commits to main since this release
9fec5d5

Fixed

  • Hero terminal: the section switch reaches the terminal. v0.4.0 taught the hero
    that its "view projects" button must not point at a section that does not
    render, but the terminal directly above it went on typing ls projects/ and
    listing the repositories of a section the reader could not scroll to. Both
    remaining commands now follow the plan: ls projects/ follows the projects
    section, and cat stack.txt follows about, which is where the skills live.
  • Hero terminal: a command with no output is no longer typed at all. Only the
    blog listing had ever followed that rule; cat stack.txt and ls projects/
    were unconditional, so a site that filled nothing in — the one CI has been
    building all along — greeted its reader with two commands and two blank lines
    under them. This half is fixed in the script rather than the template, so an
    empty value produces no command whatever put it there. whoami is the stated
    exception and always runs: its output is the page's own identity, not a
    section's data, so no switch can empty it.
  • Hero terminal: the reserved height counts the rows the text takes, not the
    lines it is written in. --hero-lines was a count of logical lines, and
    .term__body wraps — so on a 360px phone five of the exampleSite's fifteen
    lines take two rows each, the box reserved 369px for 480px of text, and it grew
    under the reader line by line as the animation typed: the exact shift the
    reservation exists to prevent, on the viewport where it is scored hardest. Only
    the browser knows the box's width and the font's advance, so terminal.js now
    measures both and writes the corrected count back before the first character is
    typed — and again whenever the box changes size or JetBrains Mono arrives under
    font-display:swap. Width is counted in terminal cells rather than characters,
    so a full-width glyph costs the two it really takes: a Japanese subtitle would
    otherwise model at half its width and the box would come out short again, which
    is this bug wearing the fix as a disguise. The blinking cursor is counted too —
    it belongs to no line of the script, and the closing prompt is where it comes to
    rest. What the template emits is unchanged and becomes the floor: the number a
    reader gets before the script runs, or without it. Not a regression from the
    entry below: v0.4.0 reserved the identical height by a different route and
    carried the same pre-wrap, so this is older than both.
  • Hero terminal: the reserved height follows the commands that actually render.
    It was a constant 12 lines plus one per post, which was right only while all
    three commands always rendered; drop one and the box reserved three lines it
    never filled, leaving a block of dead space under the hero — the same class of
    bug as section--last sitting on a section that was no longer last. The
    template now counts the lines it is about to emit and passes them as
    --hero-lines, replacing the --hero-posts variable and the
    .term__body--posts class, which are gone. CI recomputes the count from the
    rendered data-* attributes and holds the variable to it.
  • Config: a param written as the wrong type no longer takes the build down.
    sections.html has always stated the rule in its header — no configuration
    may fail the build — and normalised the four section tables to keep it. But
    every partial that read site.Params.<x> straight bypassed that, so the
    promise held in the one file that made it and nowhere else. Thirteen
    configurations aborted a build: [params.hero], [params.contact],
    [params.footer] and [params.navbar] written as scalars;
    [params.footer.socialNetworks], [params.hero.socialLinks] and
    [params.about.skills] the same one level down; items written as a scalar
    under about.skills, projects and experience; a jobs list inside an
    experience entry; and a list of bare strings where projects, experience or
    socialLinks expect a list of tables. Each now warns, names the param, and
    falls back.
    Four of the thirteen broke every page, not the home alone — head.html,
    footer.html and nav.html run site-wide, so a scalar hero, contact,
    footer or navbar took the 404 and every blog post with it. navbar was
    the sharpest of them: nav.html is the file the invariant names, and
    sections.html already guarded that same param for its showBlog gate, so
    the theme disagreed with itself about [params.navbar] in two files.
  • Config: three new partials carry that — params-table.html,
    params-list.html and params-scalar.html — and every consumer reads through
    them. A guard on a parent says nothing about its children, so nested tables go
    through the same helper; that is the whole reason six of the thirteen existed.
    Lists are tested for being lists rather than for truth: first does not
    reject a string, it slices its bytes, so items = "Go" would have rendered
    71 · 111 instead of failing anywhere a consumer could see it. Entries
    dropped from a list are counted in the warning, so a typo that silently
    removes one project from six is reported rather than simply absent — and
    entries are checked in both directions now, so a table written where a bare
    skill belongs is dropped and counted rather than rendering map[a:1] into a
    skill chip.
  • Config: the mirror direction is covered too — a scalar-shaped param written as
    a table or a list. It fails differently and had to be guarded separately:
    these never reach a range or a field lookup, they reach plainify,
    relURL, absURL, markdownify or urlize, all of which cast to string and
    abort when the cast fails. Eight more configurations, on top of the thirteen
    above: [params.description], [params.favicon] and [params.ogImage], read
    in head.html, so all three took whole sites down; a post's own image, from
    its front matter, in head.html for og:image and again in single.html for
    the featured banner; and the prose fields — [params.about] content, a
    project entry's content and title, and an experience job's content.
    The per-entry ones name the entry in the warning, by repo or by title once
    the title itself has been through the guard, so a list of six says which one.
    A param that is only ever printed is left alone on purpose: map[a:1] on the
    page is wrong but does not stop the build, and warning about it would report
    the same mistake twice for the reads that do go through a cast.
  • Config: gate 3 type-checks [params.about] content for the same reason it
    type-checks the lists — a table there is truthy, so it admitted the section
    and then rendered it as an empty shell.
  • Config: a warning about an experience entry with no company no longer
    degrades into printf's own error syntax. %q on a nil printed the warning as
    items %!q(<nil>) jobs must be a list, turning the half that names the broken
    entry into noise. CI now watches the warnings for printf garbage as well as
    the pages, since the log is the only place this one could ever appear.
  • Config: gate 3 in sections.html now type-checks the list-shaped params as
    well as testing them for emptiness. A scalar items is truthy, so it used to
    pass the gate and reach the partial; with the partials guarded the build
    survives, but the section would render with nothing in it — the defect v0.4.0
    closed. The warning has to come from the gate for the same reason: once the
    gate drops the section its partial never runs, so a guard that only warned
    inside the partial would go quiet exactly when the config is wrong.
  • SEO: a site that never set [params.hero] subtitle no longer publishes
    <title>Site — %!s(&lt;nil>)</title>. Go's printf has no nil case for
    %s, so the missing param was formatted straight into the page — on the home
    page of every site that skipped it, including the bare site CI has been
    building all along. Nothing warned, so --panicOnWarning could not see it and
    the build stayed green. The title now falls back to the site name alone. CI
    asserts no built page contains printf's error syntax, across every fixture.
  • SEO: jobTitle and description are omitted from the JSON-LD when unset
    instead of emitted as null. jsonify renders a nil as valid JSON, so this
    was never the defect above — but "jobTitle":null asserts that the person has
    no job title, where saying nothing asserts only that this site left the field
    empty.

Changed

  • Hero terminal: cat stack.txt now follows [params.about.skills] enable,
    which has to be an explicit true — an absent key counts as off, the same
    reading the skills block inside the about section and the section index have
    always used. The switch used to hide that block while the terminal above kept
    announcing the same list — one switch that meant two different things
    depending on where you looked. Sites that write enable = true, the
    exampleSite among them, are unaffected. A site that lists items without
    an enable key does lose cat stack.txt: it was already not rendering the
    skills block, and the terminal now agrees with the page instead of announcing
    a list the reader cannot find.
  • Docs: RELEASING.md now says what 0.x does with a breaking change. The
    SemVer table had no row for it, and the major row's example read 0.3.0
    1.0.0 — which taken literally made v0.4.0, breaking by the table's own
    definition, a 1.0.0. It was cut as 0.4.0 deliberately, per
    SemVer §4: while the theme is 0.x a
    breaking change goes in the minor, and 1.0.0 is reserved for the deliberate
    statement that the contracts are stable. The major row now counts from
    1.0.0 so it stops implying otherwise. Wording only — the script chooses
    nothing, the number is still yours to pass.

Full changelog: v0.4.0...v0.5.0