Skip to content

feat(fsh_theme): add AWK example to theme preview - #202

Merged
ss-o merged 1 commit into
mainfrom
feature-198
Oct 11, 2026
Merged

ss-o merged 1 commit into
mainfrom
feature-198

Conversation

@ss-o

@ss-o ss-o commented Oct 11, 2026

Copy link
Copy Markdown
Member

Summary

  • Add awk '{print $1}' to the fsh_theme --test preview using the existing single-quote escaping pattern, as suggested in feat: add a single quote command for the tests #198.
  • The example shows the AWK subtle-bg, keyword and bracket styles. It remains inside the existing repeat 0 sample block.

Closes #198.

Verification

  • Passed: native Zsh syntax validation and zcompile / zcompile -t for functions/fsh_theme.
  • Passed: isolated preview-buffer capture preserves single quotes and literal $1, and the existing highlighter produces the AWK background region in the full preview. The same check fails on the unchanged base because the sample is absent.
  • Passed: env -u FPATH zsh -f tests/integration/test-theme-persistence.zsh, including interactive preview cleanup and theme-storage preservation.
  • Passed: git diff --check.
  • Local checks ran on Linux with Zsh 5.9.2. CI tests Zsh 5.8 and 5.9.2 on Linux, with ZUnit on Linux and macOS.

Agent handoff

No handoff needed.

Include the single-quoted AWK example suggested in #198 so the preview
shows the AWK subtle-bg style, keywords and braces.

Refs #198
@github-actions

Copy link
Copy Markdown

PR highlighting performance

Buffer Base PR Difference
173 chars 4.579 ms 4.568 ms -0.2%
1000 chars 14.500 ms 14.467 ms -0.2%

Negative differences are faster. Medians use nine parses after one warm-up on the same runner.

Behavioral assertions

  • Pass: representative buffers produce highlighting
  • Pass: steady-state highlighting performs no full lifecycle refresh
  • Pass: buffers above the configured limit take the skip path
  • Pass: lazy and steady-state plugin resources unload cleanly

@ss-o ss-o added type:feature A request for new behavior or capability. area:plugin Plugin behavior or plugin-facing work. labels Oct 11, 2026

@ss-o ss-o left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fallback review under ADR-0026: maintainer elected, no Copilot request on 4817d05

No actionable findings. Reviewed the complete one-line diff against base and merge base 14df507cdc9c13af08bd023caa202cd7539d0918, using the bundled organization review criteria and issue #198 as the acceptance criteria.

Self-review; no independent reviewer participated.

  • Specification: PASS. functions/fsh_theme:516 adds the exact requested awk '{print $1}' example. Buffer capture verifies the quotes and literal $1; the AWK chroma produces the background region in the full preview.
  • Correctness and safety: PASS. The example uses the same quote-escaping pattern as nearby samples. It is literal data passed to the existing print -zr, inside the existing repeat 0 block. The change adds no execution, input evaluation, filesystem or network operation.
  • Zsh and compatibility: PASS. The file is a native Zsh autoload function with a declared Zsh 5.8 floor. Native syntax and compilation pass locally on Zsh 5.9.2; hosted Zsh 5.8 and 5.9.2 validation also pass. The added text uses the existing grammar and quoting convention.
  • State and lifecycle: PASS. The affected theme persistence integration test passes, including interactive preview rendering, acceptance, Ctrl-C cleanup and preserved theme storage.
  • Validation: PASS for the relevant checks. The isolated buffer/highlight check passes on this head and fails against the base because the example is missing. zsh -f -n, zcompile, zcompile -t and git diff --check pass. Hosted ZUnit passes on Linux and macOS, and hosted Trunk passes. The existing Trunk hooks ran; the extensionless change has no applicable local Trunk linters.
  • Scope, documentation and dependencies: PASS. One file and one added sample line; no public API, configuration, dependencies, CI or documented command contract changes. No documentation update is needed.

All required CI checks pass on the reviewed head, and there are no review threads. Visual rendering in the reporter's terminal was not inspected, and local Zsh 5.8/macOS checks were not run. GitHub Markdown rendering was checked through the API; desktop and narrow-screen visual rendering was not inspected. No follow-up changes are proposed.

@ss-o
ss-o merged commit 6bd1e63 into main Oct 11, 2026
15 checks passed
@ss-o
ss-o deleted the feature-198 branch October 11, 2026 05:20
@ss-o ss-o mentioned this pull request Oct 11, 2026
2 tasks done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:plugin Plugin behavior or plugin-facing work. type:feature A request for new behavior or capability.

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

feat: add a single quote command for the tests

1 participant