Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Look up when detecting Node.js/Rust/Go/etc projects? #323

Closed
lydell opened this issue Aug 6, 2022 · 2 comments
Closed

Look up when detecting Node.js/Rust/Go/etc projects? #323

lydell opened this issue Aug 6, 2022 · 2 comments
Labels
🌊 enhancement New feature or request

Comments

@lydell
Copy link

lydell commented Aug 6, 2022

Is your feature request related to a problem? Please describe

The Node.js item is only activated if the current directory contains a package.json file (test -e package.json). The Rust and Go and some other items work similarly (test -e Cargo.toml, test -e go.mod).

If I cd into a subdirectory of the project, the prompt item disappears. For example, I might do cd tests to more easily work on tests.

In my opinion I’m still in the project and would like to see that the project Node.js/Rust/Go/etc version is used.

Describe the solution you'd like

Switch to look-up package.json instead of test -e package.json and so on, where look-up is a function that checks the current directory, then the parent directory and so on until the file is found or the root is hit.

Potential downside: Performance? But we could try and measure?

@lydell lydell added the 🌊 enhancement New feature or request label Aug 6, 2022
@IlanCosman
Copy link
Owner

Yup, will do.

@IlanCosman
Copy link
Owner

Done on main, releasing soon.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 10, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
🌊 enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants