Repository navigation
fix(update-notice): suggest brew upgrade for Homebrew installs - #327
Open
erikengervall wants to merge 4 commits into
Open
erikengervall wants to merge 4 commits into
erikengervall wants to merge 4 commits into
Conversation
Contributor
There was a problem hiding this comment.
All reported issues were addressed across 3 files
Shadow auto-approve: would not auto-approve because issues were found.
View guided diff | Turn on auto-fix | Re-trigger cubic
Contributor
There was a problem hiding this comment.
0 issues found across 2 files (changes from recent commits).
Confidence score: 5/5
- Automated review surfaced no issues in the provided summaries.
- No files require special attention.
Shadow auto-approve: would auto-approve. Update notice now suggests brew upgrade only for Homebrew Cellar installs, keeping the npm hint elsewhere; adds tests and removes an uninstallable placeholder Homebrew formula. Bounded, clearly beneficial fix to incorrect update guidance.
View guided diff | Turn on auto-fix | Re-trigger cubic
…rade-for # Conflicts: # src/__tests__/utils/update-notice.test.ts # src/utils/update-notice.ts
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.
The startup update notice always tells people to run
npm install -g firecrawl-cli. For a Homebrew install that is the wrong fix: it installs a second copy through npm and leaves the brew keg stale.What changed
updateCommand()insrc/utils/update-notice.tspicks the upgrade command from where the CLI is installed. When the module lives under a Homebrew keg (.../Cellar/firecrawl-cli/...), the notice saysbrew upgrade firecrawl-cli; every other install keepsnpm install -g firecrawl-cli. It reads__dirname, which Node resolves through the bin symlink, so/opt/homebrew/bin/firecrawlmaps to the Cellar path. A plainnpm install -gwith Homebrew's Node lives in/opt/homebrew/lib/node_modulesand still gets the npm hint.formatUpdateNoticeand the sharedcolorizeUpdateNoticetake the chosen command, andmaybeShowUpdateNoticeaccepts aninstallPathsoverride for tests.homebrew/firecrawl-cli.rbdraft. It was pinned to 1.10.0 with placeholder checksums and was never installable; a tap formula built from the npm tarball replaces it.detectPackageManageris unchanged, sofirecrawl initbehaves as before.Testing
Cellar/firecrawl-cli/1.26.9/libexec, linked from abin/symlink), and ranfirecrawl statusin a TTY with a cached newer version. The notice printedRun brew upgrade firecrawl-cli to update.; the same package under a plain npm global prefix printed the npm command.pnpm run type-check,pnpm run format:checkandpnpm run buildpass. The one failing test in a full local run (parse.test.ts, "without auth ... no key") also fails onmainwhenFIRECRAWL_API_KEYis set in the shell, so it is unrelated.Summary by cubic
Fixes the startup update notice so Homebrew installs are told to run
brew upgrade firecrawl-cliinstead ofnpm install -g firecrawl-cli, which previously installed a second copy through npm and left the brew keg stale.homebrew/firecrawl-cli.rbformula, which was pinned to 1.10.0 with placeholder checksums and was never installable.Written for commit 2967425. Summary will update on new commits.