fix: narrow init keywords to { "YedPool" } so both URL spellings load#13
Merged
Conversation
dev.wezterm matches plugins by case-sensitive substring search across the encoded plugin path. After the repo rename to Wezurrect, the encoded path is "...sZsYedPoolsZsWezurrect" — which contains "Wezurrect" but NOT "resurrect" (the 's' in resurrect vs the 'z' in Wezurrect). PR #12 added "YedPool" for disambiguation but kept the stale "resurrect" keyword. With "resurrect" required AND missing from the path, dev.setup() silently returns nil; the subsequent require("resurrect.utils") fails with "module 'resurrect.utils' not found" because package.path was never updated. The plugin appears to do nothing on first install. Drop "resurrect" and "wezterm" — "YedPool" + "Wezurrect" together uniquely identify this plugin.
The previous commit on this branch used keywords = { "YedPool", "Wezurrect" },
which works only for users who installed via the canonical URL
https://github.com/YedPool/Wezurrect. But the README's Quick Start (and
all 8 install snippets in README.md) tells users to require
https://github.com/YedPool/resurrect.wezterm. GitHub 301-redirects this
to /Wezurrect, but wezterm caches the plugin under the URL the user
supplied -- so README-following users have an encoded path of
"...sZsYedPoolsZsresurrectsDswezterm" which contains "YedPool" but NOT
"Wezurrect" (case-sensitive substring; lowercase "wezterm" doesn't
match capital "W").
Net effect of the previous commit: it would have moved the load failure
from "fresh installs via canonical URL" (small cohort) to "fresh installs
via README" (large cohort). Same bug, different cohort.
Drop to a single-keyword match: "YedPool". Properties:
- Matches both URL spellings (both encode "YedPool" verbatim).
- Excludes the upstream MLFlexer fork (different account name).
- Trade-off: stops being unique if YedPool publishes another wezterm
plugin in future. Acceptable today; revisit if/when that happens.
Add an inline comment explaining the constraint so future maintainers
don't fall into the same trap.
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.
Summary
After the repo rename to Wezurrect, the encoded plugin path on disk no longer contains
resurrect— but PR #12 kept"resurrect"in the keyword list. With it required and missing,dev.setup()returnsnil,package.pathis never updated, andrequire("resurrect.utils")fails on a fresh install:Why a single-keyword match (
{ "YedPool" })wezterm.plugin.require()caches the plugin under the URL the user supplied, not the redirect target. Two URL spellings reach this codebase:Wezurrect?YedPool?https://github.com/YedPool/Wezurrect…sZsYedPoolsZsWezurrecthttps://github.com/YedPool/resurrect.wezterm(README's snippet)…sZsYedPoolsZsresurrectsDsweztermwezterm, notWezurrect)dev.wezterm uses case-sensitive
:findand requires every keyword to substring-match. The only substring common to both spellings isYedPool, which also correctly excludes the upstream MLFlexer fork.Trade-off:
keywords = { "YedPool" }would stop being unique if YedPool ever publishes another wezterm plugin. Acceptable today; revisit when that happens.Change
Test plan
https://github.com/YedPool/Wezurrect→ plugin loads, Alt+S/R/W keybindings appear inwezterm show-keysoutput.https://github.com/YedPool/resurrect.wezterm→ plugin loads (would have failed with the previous commit on this branch; needs verification before merge).wezterm.plugin.list()returns the expected encoded path; "YedPool" substring is present in both spellings.Commits in this PR
1937a32first attempt ({ "YedPool", "Wezurrect" }) — superseded; would have broken README-following installs1d0ac46narrowed to{ "YedPool" }covering both URL spellings (current)🤖 Generated with Claude Code