-
-
Notifications
You must be signed in to change notification settings - Fork 13k
code-server 3.9.2 #73986
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
code-server 3.9.2 #73986
Conversation
|
CI tests are using Node We introduced a tighter restriction around Node requirements in AH - my teammate found this in your docs:
I wonder if it would be possible to echo that in CI and link to the docs - it would definitely be helpful for folks newer to the homebrew ecosystem! |
We introduced a tighter restriction around Node requirements in 3.9.2 because when you're developing/contributing, there are issues with Node v15. This is based on us having to align with the requirements of VS Code.
==> /opt/homebrew/Cellar/code-server/3.9.2/bin/code-server --extensions-dir=. --install-extension ms-python.python
env: node: No such file or directory Hmm...investigating |
This updates the URL in the comment. This uses a basic theme extension because it doesn't update often and is more reliable for testing.
Co-authored-by: Carlo Cabrera <[email protected]>
Co-authored-by: Carlo Cabrera <[email protected]>
Not sure how CI would know when to link the docs -- it just prints out build errors but doesn't parse them. However, maybe there's a solution here I'm just not thinking of. PRs to improve things appreciated. |
==> /opt/homebrew/Cellar/code-server/3.9.2/bin/code-server --extensions-dir=. --install-extension wesbos.theme-cobalt2
env: node: No such file or directory Not sure why that's failing... going to check to make sure it's working for me locally (by installing from npm) |
Your issue might be that the versioned Node formulae are keg-only. Is there an environment variable that Edit: Oh, wait. The formula already does that. Except that it prepends the wrong path in the env script. |
What is the right path? I'm having trouble finding this in the docs. This was passed on from a previous maintainer, and as you can see, we need to add more documentation for current maintainers. |
Try this: diff --git a/Formula/code-server.rb b/Formula/code-server.rb
index 58b528c1654..fbc2313c6bf 100644
--- a/Formula/code-server.rb
+++ b/Formula/code-server.rb
@@ -24,9 +24,12 @@ class CodeServer < Formula
end
def install
+ node = Formula["node@14"]
+
system "yarn", "--production", "--frozen-lockfile"
libexec.install Dir["*"]
- env = { PATH: "#{HOMEBREW_PREFIX}/opt/node/bin:$PATH" }
+
+ env = { PATH: "#{node.opt_bin}:$PATH" }
(bin/"code-server").write_env_script "#{libexec}/out/node/entry.js", env
end You could've probably just done |
Ah! Thank you! 🙏 As you can probably tell, I haven't written Ruby before. We'll make sure to update the docs in |
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.
Looks good! Thanks, @jsjoeio!
🤖 A scheduled task has triggered a merge. |
Created with
brew bump-formula-pr
.