Skip to content

Restore Harper Pro branding in CLI and installer output, lost since 5.1.0-beta.1 - #997

Merged
kriszyp merged 4 commits into
mainfrom
kris/runtime-product-name
Oct 23, 2026
Merged

kriszyp merged 4 commits into
mainfrom
kris/runtime-product-name

Conversation

@kriszyp

@kriszyp kriszyp commented Oct 7, 2026 •

Copy link
Copy Markdown
Member

⊙ Problem

Harper Pro's CLI and installer have printed "Harper" since 5.1.0-beta.1. The build's Perl rewrite still targets JavaScript files that core moved to TypeScript. Retargeting that blanket rewrite would also corrupt multipart boundaries and already-branded strings.

🤔 Restore the deliberate product name

5.0.x shipped "Harper Pro" intentionally (#11). Restore that output rather than keeping the accidental regression. Keep the existing v5.4 release target; an earlier backport remains a separate decision.

💡 Solution

Core reads the running package's productName through PRODUCT_NAME; harper#3078 is merged and included in Pro main. This PR inherits main's core revision unchanged, with no submodule change or companion dependency.

🤔 Visible wording

The [notify] startup line and operations restart response also regain "Harper Pro", as in 5.0.x. Keep this intentional change and mention it in release notes. No documentation companion: command syntax, configuration, and API shapes are unchanged; productName belongs to the distribution.

✅ Verification

  • Build, typecheck, required lint, changed-file Prettier, and shell syntax checks pass.
  • Full unit gate: 1,958 passing, 2 pending. Branding regression tests cover compiled PRODUCT_NAME, the real CLI's help output, and manifest shadowing in npm pack.
  • Consumer-install CI checks the actual installed release tarball's help output, after packaging rewrites the manifest. This is the release-artifact verification route.
  • Clone-node integration suites pass, including failure recovery and interrupted-copy resume. The full integration run, with concurrency 2, hit the 1,200-second bound after cluster tests; no failed assertions were reported before timeout. This is incomplete full-suite coverage.

🤖 Generated by OpenAI Codex; posted via @kriszyp.

Release target: v5.4 — preserves the existing release decision for this branding restoration
Related PRs: #992 independent (changes build scripts, not productName), #1092 independent (replication checkpoints), #956 independent (merged table-drop fix), #981 overlaps (its merged packaging path is checked by the installed-artifact assertion), #998 independent (merged origin cursors), #1001 independent (merged core baseline; no pointer change here), #1065 independent (no core change here), #1062 independent (core sync already in base)
Complexity: easy
PR QA: skipped @ b1e281e — maintenance rebase only; existing CLI and installed-artifact tests cover branding

Deferred findings

Review-Coverage: authored=codex; ran=gemini,claude,cursor-grok; adjudicated=domain; declined=cursor-composer,cursor-kimi,cursor-muse,muse; rounds=7; full=5 @ b1e281e

Review-Attention: study ~14m (critical: cloneNode.ts; decisions: default-command-assertion, lifecycle-log-branding, branding-scope, release-target-vs-evidence; raised: earlier round at this SHA) @ b1e281e

@kriszyp kriszyp added this to the v5.4 milestone Oct 7, 2026

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Code Review

This pull request transitions the rebranding of the application to 'Harper Pro' from a build-time script replacement to a dynamic configuration using PRODUCT_NAME from packageUtils.js. It updates package.json, updates log messages in cloneNode.ts to use the dynamic product name, and introduces a new test suite to verify the branding. The review feedback correctly identifies a cross-platform compatibility issue in the test suite where calling execFileSync with npm will fail on Windows, and provides a robust solution to resolve the correct command name based on the platform.

Comment thread unitTests/bin/productName.test.mjs Resolved

@DavidCockerill DavidCockerill left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Restoring the brand is the right call. 5.0.x shipped it on purpose, and a release-note line for the [notify] and restart text covers the visible change. One thing before approval: please get harper#3078 rebased and re-pin core (see inline), because nothing can be pushed here once it's approved. The tarball check from last round is still open and optional.

Findings drafted by claude-opus-5-5 via daivid-review, reviewed and posted by @DavidCockerill.

Comment thread core Resolved
Comment thread unitTests/bin/productName.test.mjs Resolved

@DavidCockerill DavidCockerill left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks for the help check on the installed tarball. That's where the brand went missing last time, so it's the right place to check it. The core pin still points at edce42a27 and would drop harper#3064 on merge; please rebase harper#3078 and re-pin core, then I'm happy to approve.

Findings drafted by claude-opus-5-5, worded by gpt-6-sol via daivid-review, reviewed and posted by @DavidCockerill.

@kriszyp
kriszyp force-pushed the kris/runtime-product-name branch from f77c178 to 5ff181a Compare October 18, 2026 22:48

@DavidCockerill DavidCockerill left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM

kriszyp and others added 4 commits October 22, 2026 06:59
…Name instead of rewriting core at build time

build-pro.sh ran `perl -pi -e 's/Harper/Harper Pro/g'` over core/bin/*.js and
core/utility/install/installer.js. Core moved those to TypeScript, so every release since
5.1.0-beta.1 has printed "Harper" for the startup banner and installer prompts. Retargeting
the rewrite at the .ts sources would also rewrite the deploy multipart boundary
("----Harper ProMultipart", an unquoted space) and remote-target messages.

Core now reads the product name from the root package.json at runtime, so declare
"productName": "Harper Pro", drop the rewrite, and drop the cleanup trap's
`git restore .` in core, which only existed to undo it (and discarded a developer's
uncommitted core edits on every `npm run package`). Clone-node's own install/start
messages use the same name.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ro product-name test

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…pack test spawn npm on Windows

The unit test packs the checkout, but the published archive is repacked by core's
bundleDependencies prepare after it rewrites package.json, so a field dropped there would ship
"Harper" with the unit test still green. The consumer-install job now runs `harper help` from
the globally installed tarball on every OS/npm leg and requires the Harper Pro wording.

npm is npm.cmd on Windows, which execFileSync can only start through a shell since Node's
CVE-2024-27980 fix; the arguments are constant.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Dispatch-Task: fix-kriszyp_harper-pro_997-bb89df93
Co-Authored-By: OpenAI Codex <noreply@openai.com>
@kriszyp
kriszyp marked this pull request as draft October 22, 2026 13:05
@kriszyp
kriszyp force-pushed the kris/runtime-product-name branch from 5ff181a to b1e281e Compare October 22, 2026 14:07
@kriszyp
kriszyp marked this pull request as ready for review October 23, 2026 01:39
@kriszyp
kriszyp merged commit 833bad7 into main Oct 23, 2026
55 checks passed
@kriszyp
kriszyp deleted the kris/runtime-product-name branch October 23, 2026 01:39
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.

2 participants