refactor: replace find-up dependency with internal implementation#4248
Open
MarshallOfSound wants to merge 1 commit intonextfrom
Open
refactor: replace find-up dependency with internal implementation#4248MarshallOfSound wants to merge 1 commit intonextfrom
MarshallOfSound wants to merge 1 commit intonextfrom
Conversation
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.
Summarize your changes:
This PR removes the external
find-updependency and replaces it with an internal implementation incore-utils. The newfindUpfunction provides the same core functionality—walking up the directory tree to find files—while being simpler and more tailored to the project's needs.Changes:
src/find-up.tswith an asyncfindUpfunction that searches for files by walking up the directory tree from a given starting directoryspec/find-up.spec.tscovering:src/package-manager.tsandsrc/electron-version.tsto use the new internal implementationspec/package-manager.spec.tsto mock the internal functionfind-upfrompackage.jsondependenciesThe new implementation is simpler than the external dependency, removes an external dependency, and provides the exact functionality needed by the codebase.
https://preview.claude.ai/code/session_01VxunirAtie59oe2RTm1DGr