Skip to content

chore(ui): rollup of UI test conventions, say()/PS4 traces, print(width=Inf), and just ui-publish#166

Merged
CGMossa merged 5 commits into
mainfrom
chore/ui-rollup
Apr 29, 2026
Merged

chore(ui): rollup of UI test conventions, say()/PS4 traces, print(width=Inf), and just ui-publish#166
CGMossa merged 5 commits into
mainfrom
chore/ui-rollup

Conversation

@CGMossa
Copy link
Copy Markdown
Contributor

@CGMossa CGMossa commented Apr 29, 2026

Summary

Cross-cutting UI test improvements pulled out of #154 so that PR can stay focused on the get-recursive feature. Five commits:

  1. Blank-line separators before === === headers across main_status.sh, main_progress.sh, main_parallel.sh, main.sh.
  2. Cleanup-hint printf at the end of every main*.sh.
  3. Shared mktemp suffix across related dirs (cli/rpkg repo + storage) in each main*.sh.
  4. just install-all reminder echo at the top of every main*.sh.
  5. PS4='> ', say(), print(width = Inf), and just ui-publish recipes:
    • ui/helpers.sh adds mkrandfile (hides head -c from set -x), PS4='> ' as the xtrace prefix, and say for echoes that shouldn't leave a + echo ... trace line.
    • ui/main_status.sh swaps bare echo / echo "=== ... ===" for say, and pipes tibble-returning R calls to |> print(width = Inf) for full-width log output.
    • ui/main.sh, ui/main_parallel.sh get the same print(width = Inf) change.
    • justfile adds ui-run, ui-render, ui-publish-only, and ui-publish — runs each ui/main*.sh, wraps the log into ui/output/ui-<NAME>.html, publishes to alx project from .alx/config.yaml. Names driven by ui_names.

Notes:

Test plan

  • bash -n clean on all touched ui/main*.sh
  • just --list enumerates the new ui-* recipes
  • just ui-publish was used to regenerate and publish all five HTML artifacts to alx during this session
  • R tibbles render with full width in ui/output/*.html — visual verification

🤖 Generated with Claude Code

CGMossa and others added 5 commits April 29, 2026 19:45
Each main*.sh script's section headers now have a preceding blank-line
echo so the output blocks are visually separated when running with
set -x. No behaviour change.
Dirs created within a single script run now share a 3-char random suffix so
the relationship between them is visible at a glance:

  dvs_repo_cli_fVY    dvs_repo_rpkg_fVY
  dvs_storage_cli_fVY dvs_storage_rpkg_fVY

Implementation: mktemp -d the first dir to capture a unique suffix, then
mkdir the rest using the same tail.

main_progress.sh has two scenarios → two suffixes (one per scenario).
main_parallel.sh has one suffix shared across the fixture, the CLI pair,
and the four R variants; the R variants get a `_R<n>_` infix to stay
distinct while keeping the same trailing run-suffix.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Adds the same `printf 'Cleanup: bash %s/cleanup.sh\n' "$SCRIPT_DIR"` line
that main_progress.sh already had to main.sh, main_parallel.sh,
main_recursive.sh, and main_status.sh — so every demo script reminds the
user how to remove the temp dvs_repo_*/dvs_storage_* dirs it created.

main.sh's dead commented-out cleanup hint is replaced with the real call.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Same NOTE echo (added to main_recursive.sh in the prior commit) is now
at the top of main.sh, main_parallel.sh, main_progress.sh, and
main_status.sh — right after the trap line, before SCRIPT_DIR. Setup
preamble is now identical across all five demo scripts.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…ecipes

- ui/helpers.sh: add `mkrandfile` (single-file urandom helper that hides
  the head -c trace under set -x), set PS4='> ' as the xtrace prefix,
  and add a `say` helper that echoes without leaving an xtrace line for
  the echo itself (used for blank-line separators and "=== ===" headers).
- ui/main_status.sh: replace bare `echo` and `echo "=== ... ==="` with
  `say`, and pipe each tibble-returning R call to `|> print(width = Inf)`.
- ui/main.sh, ui/main_parallel.sh: pipe tibble-returning R calls to
  `|> print(width = Inf)` for the same reason.
- justfile: add `ui-run`, `ui-render`, `ui-publish-only`, and a combined
  `ui-publish` recipe that runs each ui/main*.sh, wraps the log into
  ui/output/ui-<NAME>.html, and publishes to the alx project recorded
  in .alx/config.yaml. Names are driven by `ui_names`.
@CGMossa CGMossa merged commit 385ccf4 into main Apr 29, 2026
1 check passed
@CGMossa CGMossa deleted the chore/ui-rollup branch April 30, 2026 13:57
CGMossa added a commit that referenced this pull request May 4, 2026
ui/main_recursive.sh lives only on the unmerged feat/get-recursive branch.
PR #166 added the name to ui_names without the script, causing
just ui-publish to fail on the recursive entry. Restore when
feat/get-recursive merges.

Co-authored-by: Claude Opus 4.7 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant