This repository was archived by the owner on Jul 14, 2026. It is now read-only.
improves the update message in case of global install.#337
Merged
Conversation
Germandrummer92
approved these changes
Jan 19, 2026
Greptile found no issues!From now on, if a review finishes and we haven't found any issues, we will not post anything, but you can confirm that we reviewed your changes in the status check section. This feature can be toggled off in your Code Review Settings by deselecting "Create a status check for each PR". |
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
In case the user installed globally, this gives a hint to proceed.
Greptile Summary
Improved the error message when
package.jsoncannot be found at~/.local/packages. The new message explicitly guides users who installed the CLI globally via npm to usenpm update -g @octomind/octomindinstead of showing a generic "please update manually" error.~/.local/packages) where the CLI looks forpackage.jsonConfidence Score: 5/5
Important Files Changed
Sequence Diagram
sequenceDiagram participant User participant CLI as octomind update participant FS as File System participant NPM as npm User->>CLI: Run update command CLI->>FS: Check if ~/.local/packages/package.json exists alt package.json not found (global install) FS-->>CLI: File not found CLI->>User: Error: Cannot find package.json at ~/.local/packages<br/>If you installed globally via npm, run:<br/>npm update -g @octomind/octomind CLI->>CLI: process.exit(1) else package.json exists (local install) FS-->>CLI: File exists CLI->>NPM: Check if npm is available alt npm not found NPM-->>CLI: Not found CLI->>User: Error: Cannot determine location of npm CLI->>CLI: process.exit(1) else npm found NPM-->>CLI: npm available CLI->>NPM: Execute npm install @octomind/octomind@latest NPM-->>CLI: Installation result CLI->>User: Update complete ✔ end end