Skip to content

fix(search): improve project root path detection logic#1178

Open
beyondkmp wants to merge 2 commits intoelectron:mainfrom
beyondkmp:projectDir
Open

fix(search): improve project root path detection logic#1178
beyondkmp wants to merge 2 commits intoelectron:mainfrom
beyondkmp:projectDir

Conversation

@beyondkmp
Copy link
Copy Markdown

@beyondkmp beyondkmp commented Apr 6, 2025

My project structure is as follows:

/User/test/project/app/

There is a yarn.lock file under /User/test, and a pnpm-lock.yaml file under project. The project root directory I want to obtain is /User/test/Project, but what is returned is /User/test.

We need to search for all three, and then return the longest one.

@beyondkmp beyondkmp requested a review from a team as a code owner April 6, 2025 01:55
Copy link
Copy Markdown
Member

@erickzhao erickzhao left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you address the lint failures?

Comment thread src/search-module.ts Outdated
Comment thread src/search-module.ts Outdated
Copy link
Copy Markdown
Member

@erickzhao erickzhao left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we also add additional test coverage for this use case?

@beyondkmp
Copy link
Copy Markdown
Author

Yes. UT is added.

@beyondkmp beyondkmp requested a review from erickzhao May 29, 2025 00:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants