feat: 2.0.0 — namespace bricks:, MCP tools convention, self-update (breaking)#85
Merged
Merged
Conversation
Pure function that detects npm/pnpm/yarn from npm_execpath env var and returns the appropriate global install command for @focus-mcp/cli. No I/O: caller is responsible for execution (MCP paradox). Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Without this, dev-publish generates tags like '0.0.0-dev-<timestamp>' instead of '<next-version>-dev-<commit>'. Setting useCalculatedVersion and a commit-based template fixes the preview version format. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…breaking) - focus update / upgrade now self-update the CLI (breaking: no longer updates bricks) - Without args: print the npm/pnpm/yarn command to run for self-update - With --all: also update all installed bricks via bricks:update --all - With <brick> arg: ERROR with guidance to use bricks:update <name> - Add bricks: namespace: bricks:install, bricks:remove, bricks:list, bricks:search, bricks:update, bricks:load, bricks:unload - Flat aliases (install, remove, list, search) remain as back-compat Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…breaking) Renames: - focus_list → focus_bricks_list - focus_load → focus_bricks_load - focus_unload → focus_bricks_unload - focus_reload → focus_bricks_reload - focus_search → focus_bricks_search - focus_install → focus_bricks_install - focus_remove → focus_bricks_remove - focus_update → focus_bricks_update (focus_upgrade removed from MCP) - focus_tools → split into 6: focus_tools_hide/show/pin/unpin/list/clear - (new) → focus_self_update (returns command to run for CLI update) focus_catalog_add/remove/list kept as-is (already namespaced). focus_tools_* are immune to the hidden filter (always visible). Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Update start.test.ts: all focus_* tool names updated to focus_bricks_* - Replace focus_tools singleton tests with 6 distinct focus_tools_* tests - Update bench mode tests to use new tool names - Update isHiddenTool tests: focus_tools_* are now immune (not focus_tools) - Update ListTools count from 14 to 19 (8 bricks + 3 catalog + 1 self + 6 tools) - Add cli-updater.test.ts: 100% coverage of detectPackageManager / buildUpdateCommand / cliUpdater Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
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
This PR introduces breaking changes for the 2.0.0 release of
@focus-mcp/cli.Breaking changes
MCP tools renamed to
focus_<namespace>_<action>pattern:focus_install→focus_bricks_installfocus_remove→focus_bricks_removefocus_search→focus_bricks_searchfocus_load→focus_bricks_loadfocus_unload→focus_bricks_unloadfocus_reload→focus_bricks_reloadfocus_update→focus_bricks_updatefocus_upgrade→ removed from MCP (usefocus_bricks_update)focus_tools(singleton withactionarg) → split into 6:focus_tools_hide,focus_tools_show,focus_tools_pin,focus_tools_unpin,focus_tools_list,focus_tools_clearfocus_self_update— returns the shell command to self-update the CLICLI
focus update/focus upgradenow self-update the CLI:focus update→ prints the npm/pnpm/yarn command to update@focus-mcp/clifocus update --all→ also updates all installed bricksfocus update <brick>→ ERROR with guidance to usefocus bricks:update <name>New
bricks:namespace for brick management:focus bricks:install,bricks:remove,bricks:list,bricks:search,bricks:update,bricks:load,bricks:unloadadd,remove,list,search) remain permanent back-compatCI fix (also included):
.changeset/config.jsonsnapshot config updated to useuseCalculatedVersion+ commit-based template to fix dev-publish version tags.Files changed
src/commands/cli-updater.ts— new module: detects npm/pnpm/yarn, returns self-update commandsrc/commands/cli-updater.test.ts— 100% coverage of cli-updatersrc/bin/focus.ts— newbricks:namespace + refactoredupdate/upgradecommandssrc/commands/start.ts— all MCP meta tools renamed,focus_toolssplit into 6src/commands/start.test.ts— updated for all renames (263 tests pass).changeset/2.0.0-namespace-self-update.md— major changeset entry.changeset/config.json— snapshot config fixCHANGELOG.md— 2.0.0 breaking changes sectionTest plan
pnpm typecheck— passes (verified locally)pnpm test— 263 tests pass, 17 test files (verified locally)pnpm lint— passes (verified locally)focus update(should print self-update command)focus bricks:update echo(should update brick)focus update echo(should print error with guidance)🤖 Generated with Claude Code