-
-
Notifications
You must be signed in to change notification settings - Fork 504
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
fix(vscode): server bin path resolution #227
fix(vscode): server bin path resolution #227
Conversation
Could you add an automation test on the CI to test this code properly? |
It is technically possible, and while I'm usually all for it, this would require a non-trivial amount of additional work, for which I'm not willing to invest time at the moment. Considering that the VS Code extension rarely changes, I think that doing a manual test will suffice for now. Feel free to PR something if/when this is merged. |
what's left for this pull request to be considered ready for review? i'd love it if it managed to get included in the next biome release |
It needs to be tested under Windows and Linux. I'll come up with a detailed test plan tomorrow. |
Alright, it works as expected on Linux. I'll be testing on a Windows VM today and then we should be good to go. |
Co-authored-by: Emanuele Stoppa <[email protected]>
@@ -363,6 +363,7 @@ async function getSocket( | |||
): Promise<string> { | |||
const process = spawn(command, ["__print_socket"], { | |||
stdio: [null, "pipe", "pipe"], | |||
shell: true, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is required to spawn the biome
binary in node_modules/.bin
under windows.
A little adjustment was needed to make it work with Windows, but it should be all good now. I'll mark the PR as ready and will let you review the code. |
"watch": "pnpm run compile -- --sourcemap --watch", | ||
"watch": "pnpm run compile --sourcemap --watch", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missed this one in #219.
Let me know if you'd rather I submit this in a separate PR.
Guys, when do you plan to add this into release? I'm trying to incorporate biome in my company's processes with several Windows machines. (Found this thread, trying to make exactly the same pull request.) |
We don't have dates for you. v1.2 will be out soon. We can release a nightly tomorrow, so you can test it and see if that works for you. |
Summary
This PR fixes an issue where the VS Code extension cannot resolve the path to the biome CLI when using certain package managers, notably pnpm.
The new strategy is to point to the
node_modules/.bin/biome
path, which is consistent for all package managers.Test Plan
Windows(not applicable at the moment)I'd like some help to test under Windows, I don't have a machine handy.