feat(branding): own the psmux status-left and sweep pre-rename "md" leftovers - #118
Merged
Conversation
…eftovers Every magent window showed ` md ` in its psmux status bar -- inherited from a personal ~/.tmux.conf, not something the product set. magent already owns the status-right hints per session, so the brand goes through the same door: decoration_argv gains `set -g status-left '#[bold,fg=green] magent #[default]'` plus `set -g status-left-length 10`. The length is load-bearing, not decoration: a personal conf with `status-left-length 5` truncates ' magent ' to 'magen' unless magent overrides it. Both ride the single decoration_argv list, so the creation batch, `up`, `up --json` and attach pick them up with no call-site change. Then the wider sweep for pre-rename "md" text on user-visible surfaces: the mobile upload PWA was still titled "md upload" end to end (page <title>, the "MD" logotype, the apple-mobile-web-app-title, the manifest short_name, the iOS Web Clip profile labels, the downloaded .mobileconfig filename, and the install-banner copy). Renaming the service-worker cache key came with the standard old-cache cleanup on activate, so the rename cannot orphan storage on an already-installed client.
Merged
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.
Why
Every magent window advertised
mdin the left corner of its psmux status bar — the last loud piece of pre-rename branding a user actually looks at all day. That text was never magent's: it came from a personal~/.tmux.conf(status-left '#[bold,fg=#a6e3a1] md #[default]'+status-left-length 5), which psmux loads at server start. A personal file can't be the product's branding, and it isn't editable from here.magent has owned per-session status-bar decoration since v3.4.0, so the brand goes through the same door the F1/F2 hints already use.
What
1. Product-owned status-left.
psmux.decoration_argvgains two argvs:The length is load-bearing, not decoration: the personal conf sets
status-left-length 5, which truncatesmagenttomagen. Setting the brand without the length ships a visibly broken word. Verified live on a throwaway-L mgszbrandsocket (created,status-left-length 5set first to simulate the personal conf, then the two decoration commands;show -greported10and the full brand string; server killed afterward). The user's live sessions and~/.tmux.confwere not touched.Both ride the single
decoration_argvlist, so the creation batch (platform/windows.py),upinteractive,up --json, and attach pick them up with zero call-site changes — pinned by a newtest_created_session_is_brandedintest_platform_contract.py(the creation batch, which is the call site furthest fromdecorate_session).2. Repo-wide user-visible "md" sweep. The mobile upload PWA was still branded "md upload" end to end — the rename had reached the manifest
name("magent upload") but nothing else.Sweep inventory
Renamed (user-visible branding)
md(from personal tmux.conf)magent(product-owned)<title>md uploadmagent upload<h1>MDmagentapple-mobile-web-app-titlemd uploadmagent uploadshort_namemd uploadmagentInstall <b>md upload</b>…Install <b>magent upload</b>…Label/PayloadDisplayName/PayloadDescription(x5)md uploadmagent uploadmd-upload.mobileconfigmagent-upload.mobileconfigmd-install-hidemagent-install-hidemd-v1magent-v1attention.md_windows_by_namemd_prefixmagent_windows_by_namecli/watch.pydocstringscripts/lint_rules.py::_starts_md_mdsuffix_starts_title_prefixTwo follow-ons the renames forced, both deliberate:
Cwould orphan the oldmd-v1cache on already-installed clients, soactivatenow deletes every cache but the current one (standard PWA boilerplate; also makes any future version bump self-clean). Failure-swallowed like the rest of the SW.md-install-hide→magent-install-hideresets the "I dismissed the install banner" flag once per existing mobile client. One extra dismissible banner; judged worth it over leaving dead branding in shipped storage.Deliberately left
MDTEST_*env vars (MDTEST_SSH_*,MDTEST_BROWSER,MDTEST_SOAK,MDTEST_MONITOR_LAB,MDTEST_INTERACTION,MDTEST_WT_COLD,MDTEST_TAILSCALE,MDTEST_ALLOW_REAL_HOME)mdsshCI alias.github/actions/setup-ssh-serverinto the runner's real~/.ssh/config.MD001–MD005custom lint rule IDsMD002_ALLOW/md003_allowedallow-list keys, gate output, CLAUDE.md). Only the private helper_starts_mdwas renamed.mdrl-,mddist-,mdml-,mdhk,mdatt,mdssh*,mdtailnet,mddr-)md = home / ".magent"path variables in e2e tests.mdfile extensions,DESIGN.md/CLAUDE.md/E6.md/E9.mddoc referencesplatform/macos.py'smdfindCHANGELOG.md,pyproject.tomlThe sweep introduces no occurrence of the pre-rename product name anywhere; the only surviving mention in the repo remains the CHANGELOG 2.0.0 rename line, as required.
Tests
test_psmux.py::TestDecorateSession— the existing argv-shape pins were extended deliberately: two new exact-argv pins (status-left,status-left-length), amagent-survives-a-restyle pin mirroring the existing F1/F2 one, a_STATUS_BRAND_LEN >= len(" magent ")relationship pin (so the number can't drift away from the text it protects), and the swallow-the-exception test's count moved 2 → 4.test_platform_contract.py::test_created_session_is_branded— new; proves the creation batch inherits the brand with no call-site change.test_upload_browser.py— the three real-Chromiumto_have_titleassertions updated in the same commit (CI-onlybrowsertier).Gate
uv run python scripts/check.py— GATE PASSED (FULL), exit 0. 949 passed, 2 skipped, coverage 76.03% (floor 52%).