Skip to content

Commit

Permalink
Merge pull request #177454 from branchvincent/node-shebangs
Browse files Browse the repository at this point in the history
misc: drop unneeded scripts
  • Loading branch information
BrewTestBot committed Aug 2, 2024
2 parents d3b4aec + bf62c6d commit 24d4baf
Show file tree
Hide file tree
Showing 5 changed files with 40 additions and 69 deletions.
26 changes: 8 additions & 18 deletions Formula/a/apify-cli.rb
Original file line number Diff line number Diff line change
@@ -1,35 +1,25 @@
require "language/node"

class ApifyCli < Formula
include Language::Node::Shebang

desc "Apify command-line interface"
homepage "https://docs.apify.com/cli"
url "https://registry.npmjs.org/apify-cli/-/apify-cli-0.20.2.tgz"
sha256 "dfe8bf7a168cf221ef85380b78c3b7b56c1b19b059f8ec4003f3e9c9c2bd6bb0"
license "Apache-2.0"

bottle do
sha256 cellar: :any_skip_relocation, arm64_sonoma: "b4a1a87d5b03c8ba002b879b6254aa8edde076a7adeeee92c186eef31f2efdd2"
sha256 cellar: :any_skip_relocation, arm64_ventura: "b4a1a87d5b03c8ba002b879b6254aa8edde076a7adeeee92c186eef31f2efdd2"
sha256 cellar: :any_skip_relocation, arm64_monterey: "b4a1a87d5b03c8ba002b879b6254aa8edde076a7adeeee92c186eef31f2efdd2"
sha256 cellar: :any_skip_relocation, sonoma: "3b827b72e552d84f7783133d1c8bbc8c9970e4152a0ff5c6680713d1fb65ca5a"
sha256 cellar: :any_skip_relocation, ventura: "3b827b72e552d84f7783133d1c8bbc8c9970e4152a0ff5c6680713d1fb65ca5a"
sha256 cellar: :any_skip_relocation, monterey: "3b827b72e552d84f7783133d1c8bbc8c9970e4152a0ff5c6680713d1fb65ca5a"
sha256 cellar: :any_skip_relocation, x86_64_linux: "f37274bf651075a49f2bcfea9071fbce5d0e5539b210641df7e7fa36186b8882"
rebuild 1
sha256 cellar: :any_skip_relocation, arm64_sonoma: "e937e9d467b1d3b055c2b00593e4612c54c469a28f4dd4f8e999e0919e94b0b4"
sha256 cellar: :any_skip_relocation, arm64_ventura: "e937e9d467b1d3b055c2b00593e4612c54c469a28f4dd4f8e999e0919e94b0b4"
sha256 cellar: :any_skip_relocation, arm64_monterey: "e937e9d467b1d3b055c2b00593e4612c54c469a28f4dd4f8e999e0919e94b0b4"
sha256 cellar: :any_skip_relocation, sonoma: "412ec2fac67bb901b3d66f1c2b4f5f983472410bf2b8717a0b68d8d1059687c3"
sha256 cellar: :any_skip_relocation, ventura: "412ec2fac67bb901b3d66f1c2b4f5f983472410bf2b8717a0b68d8d1059687c3"
sha256 cellar: :any_skip_relocation, monterey: "412ec2fac67bb901b3d66f1c2b4f5f983472410bf2b8717a0b68d8d1059687c3"
sha256 cellar: :any_skip_relocation, x86_64_linux: "afea6964352ba306bbf32c79e177509dad9f15f7cd484795e963fbf2b5812546"
end

depends_on "node"

def install
system "npm", "install", *std_npm_args
# We have to replace the shebang in the main executable from "/usr/bin/env node"
# to point to the Homebrew-provided `node`,
# because otherwise the CLI will run with the system-provided Node.js,
# which might be a different version than the one installed by Homebrew,
# causing issues that `node_modules` were installed with one Node.js version
# but the CLI is running them with another Node.js version.
rewrite_shebang detected_node_shebang, libexec/"lib/node_modules/apify-cli/bin/run.js"
bin.install_symlink Dir["#{libexec}/bin/*"]
end

Expand Down
24 changes: 10 additions & 14 deletions Formula/b/bcoin.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
require "language/node"

class Bcoin < Formula
desc "Javascript bitcoin library for node.js and browsers"
homepage "https://bcoin.io"
Expand All @@ -9,16 +7,14 @@ class Bcoin < Formula
head "https://github.com/bcoin-org/bcoin.git", branch: "master"

bottle do
rebuild 2
sha256 arm64_sonoma: "7ce0533a06a8fbf879814bb168ac8582def5d66a73fd341caf3d265dce7fe4bf"
sha256 arm64_ventura: "c3c02702652f0f567697cc614212a757d29fb3ee3d80ec9345dc7d00e10dd421"
sha256 arm64_monterey: "777aa63316694628e1c88cd4ad73949ac2c32b97aac6d5e196c82d2a0040c13c"
sha256 arm64_big_sur: "304cc113c0dc1dec7d70745e73b816802f4f92068ece45298957ab6feb7edc7c"
sha256 sonoma: "682758b76301db696079f2cd43d8a604acbe41a6e8faec29117feb8c53fd74b9"
sha256 ventura: "746e792b08dd522e81d1440c159997cf231044da8299726eb4ebadb0d497ffe7"
sha256 monterey: "49abdb5b53e076417bc0c0431a8dc6aff1d3030e2e2c90625a273a1545dfc8c9"
sha256 big_sur: "875527a488aec56c22828e1d314097d984d1acacd83f6533203bbd7437a6c027"
sha256 cellar: :any_skip_relocation, x86_64_linux: "43047da636f3b6b7fc3f230f4f55c4805723429531e8c1887ea896b51fcd9a38"
rebuild 3
sha256 arm64_sonoma: "c357454a7b33d7fe78ddad3a974eeb031642d8f82a49ad633c036d9a26657dcd"
sha256 arm64_ventura: "95e36e42caef34098e5802e9e8ede2cfa9b11c348eef528087ead3a1846647f9"
sha256 arm64_monterey: "2fccc2d7ac70da7276f1b951913b0f4d85ecc5990f35a0b790a9a496d432c84a"
sha256 sonoma: "48ca919ef8d01a8332ed7ce0b86d8ec413a507eecc59b7ca57d28b90202bdc1e"
sha256 ventura: "4ad6a6a70e1ae53934f27d45aecabf79139a8cc9b007613e15d87301c80bb3b0"
sha256 monterey: "8f094aa7df3a4ee4fba05e5da0fc690b8f15e01515d5c31135d3d0f2267fd150"
sha256 cellar: :any_skip_relocation, x86_64_linux: "cf6e4646d6f73fd463fe22799476324f382b7f86fe1bfcb1991ea930bcff5d56"
end

depends_on "node"
Expand All @@ -32,8 +28,8 @@ def node
end

def install
system "npm", "install", *Language::Node.std_npm_install_args(libexec)
(bin/"bcoin").write_env_script libexec/"bin/bcoin", PATH: "#{node.opt_bin}:$PATH"
system "npm", "install", *std_npm_args
bin.install_symlink Dir["#{libexec}/bin/*"]
end

test do
Expand Down
22 changes: 9 additions & 13 deletions Formula/c/cloudflare-wrangler2.rb
Original file line number Diff line number Diff line change
@@ -1,29 +1,25 @@
require "language/node"

class CloudflareWrangler2 < Formula
include Language::Node::Shebang

desc "CLI tool for Cloudflare Workers"
homepage "https://github.com/cloudflare/workers-sdk"
url "https://registry.npmjs.org/wrangler/-/wrangler-3.68.0.tgz"
sha256 "374a128e48f9455320de285d5ca95a40abc40c4e2bf5bbea7a86bd3a7e3c62dc"
license any_of: ["Apache-2.0", "MIT"]

bottle do
sha256 cellar: :any_skip_relocation, arm64_sonoma: "083e9c12247e2cc7741e34455a3077ac5d693428f5fde49d765b52fbebcf4255"
sha256 cellar: :any_skip_relocation, arm64_ventura: "083e9c12247e2cc7741e34455a3077ac5d693428f5fde49d765b52fbebcf4255"
sha256 cellar: :any_skip_relocation, arm64_monterey: "083e9c12247e2cc7741e34455a3077ac5d693428f5fde49d765b52fbebcf4255"
sha256 cellar: :any_skip_relocation, sonoma: "d45c96429584f2d0e7bfac4864da609ba3712cbde3133267198207849f89f183"
sha256 cellar: :any_skip_relocation, ventura: "d45c96429584f2d0e7bfac4864da609ba3712cbde3133267198207849f89f183"
sha256 cellar: :any_skip_relocation, monterey: "d45c96429584f2d0e7bfac4864da609ba3712cbde3133267198207849f89f183"
sha256 cellar: :any_skip_relocation, x86_64_linux: "334c699063e96ae2bc7ab2601d90e47434ebbe2e97a037674f22c03df3cf6008"
rebuild 1
sha256 cellar: :any_skip_relocation, arm64_sonoma: "72755142fec8a8fbf9631a73299a8c4229620426188f2e7dbe461e3569ac90fa"
sha256 cellar: :any_skip_relocation, arm64_ventura: "72755142fec8a8fbf9631a73299a8c4229620426188f2e7dbe461e3569ac90fa"
sha256 cellar: :any_skip_relocation, arm64_monterey: "72755142fec8a8fbf9631a73299a8c4229620426188f2e7dbe461e3569ac90fa"
sha256 cellar: :any_skip_relocation, sonoma: "d93b768b08c9fc7c5d54adba79b2692b9363a1c40af154cc1201da12c1b78171"
sha256 cellar: :any_skip_relocation, ventura: "d93b768b08c9fc7c5d54adba79b2692b9363a1c40af154cc1201da12c1b78171"
sha256 cellar: :any_skip_relocation, monterey: "d93b768b08c9fc7c5d54adba79b2692b9363a1c40af154cc1201da12c1b78171"
sha256 cellar: :any_skip_relocation, x86_64_linux: "335f2332202348a7f2b951853cb8c2610bf590550befd70fa3a24f365cec8b53"
end

depends_on "node"

def install
system "npm", "install", *Language::Node.std_npm_install_args(libexec)
rewrite_shebang detected_node_shebang, *Dir["#{libexec}/lib/node_modules/**/*"]
system "npm", "install", *std_npm_args
bin.install_symlink Dir["#{libexec}/bin/wrangler*"]
end

Expand Down
16 changes: 3 additions & 13 deletions Formula/g/grammarly-languageserver.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,8 @@ class GrammarlyLanguageserver < Formula
revision 1

bottle do
rebuild 1
sha256 cellar: :any_skip_relocation, arm64_sonoma: "b88bbd69c207d41bb1ead5ffba2879ed2961c4cbd4147536b80e83aaf821b952"
sha256 cellar: :any_skip_relocation, arm64_ventura: "b88bbd69c207d41bb1ead5ffba2879ed2961c4cbd4147536b80e83aaf821b952"
sha256 cellar: :any_skip_relocation, arm64_monterey: "b88bbd69c207d41bb1ead5ffba2879ed2961c4cbd4147536b80e83aaf821b952"
sha256 cellar: :any_skip_relocation, sonoma: "0a70d983e2f36b026141bad92136e0532a262aa072bdfde0f50a40ce54fae22e"
sha256 cellar: :any_skip_relocation, ventura: "0a70d983e2f36b026141bad92136e0532a262aa072bdfde0f50a40ce54fae22e"
sha256 cellar: :any_skip_relocation, monterey: "b88bbd69c207d41bb1ead5ffba2879ed2961c4cbd4147536b80e83aaf821b952"
sha256 cellar: :any_skip_relocation, x86_64_linux: "4d8c0beaa0099184da7a6376055ba6a188e9cebd0d0471af86e65218d0048235"
rebuild 2
sha256 cellar: :any_skip_relocation, all: "78d49db050951e7d62fd3773c446298ed08ecd2df7e064250c552cf134957816"
end

deprecate! date: "2023-11-02", because: "uses deprecated `node@16`"
Expand All @@ -23,11 +17,7 @@ class GrammarlyLanguageserver < Formula

def install
system "npm", "install", *std_npm_args
(bin/"grammarly-languageserver").write <<~EOS
#! /usr/bin/env sh
#{Formula["node@16"].bin}/node #{libexec}/bin/grammarly-languageserver "$@"
EOS
bin.install_symlink Dir["#{libexec}/bin/*"]
end

test do
Expand Down
21 changes: 10 additions & 11 deletions Formula/m/mongosh.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
require "language/node"

class Mongosh < Formula
desc "MongoDB Shell to connect, configure, query, and work with your MongoDB database"
homepage "https://github.com/mongodb-js/mongosh"
Expand All @@ -8,20 +6,21 @@ class Mongosh < Formula
license "Apache-2.0"

bottle do
sha256 arm64_sonoma: "de86e97bc451b679423b78db923ebfe24ba58f6ca12fffae7e8b1a4c750b9b55"
sha256 arm64_ventura: "7a8eedb51719daf486d92b00fe5599ef357073c67afb1a950f24d51a08c00e89"
sha256 arm64_monterey: "e21a7fd7985081ac21ffc81f6fd47c2eaefeb7bc48b762835594fb3b4cff279e"
sha256 sonoma: "395b27a7a61e2f31e182c8869330263440154916e8ee25e5ef513288b6ffd7a2"
sha256 ventura: "1a033048251bf42a88f8004cdf164d7e2b46e84fdac4688b78a191bf178bca04"
sha256 monterey: "62f84702270d620579a21359137a529c98fb2e63a41d71e4169ac0446efb12a1"
sha256 cellar: :any_skip_relocation, x86_64_linux: "63bce246fc88857bd0fbd29eb7ac186cc26f88c6ae77a7a21f7b0d9b1cd88a68"
rebuild 1
sha256 arm64_sonoma: "e3f40fb59b554d89e5c672bede9d3ecfc2556ffa1300bb225ccfe70dc2545547"
sha256 arm64_ventura: "0e3e42bc45f5a8ae6b92c3dfd86e763e172bf193188104dd2d619f08e9e0bd58"
sha256 arm64_monterey: "6bd6dfaef251caf2be2207e2f72618f06f7d386f094c8ca2b3ea59e580312236"
sha256 sonoma: "709211ff5a166f97d561a69fa84249198fd1fd6df238c4b3645dc837c3ceb761"
sha256 ventura: "918f8fba8ff250bc2092465a889a1ca7851d27dc3c52ebfaba364d7161d8b83a"
sha256 monterey: "ea1c67a938f8a6116fc7b43e1f041af108edac9784a222c9580387c18cb103e7"
sha256 cellar: :any_skip_relocation, x86_64_linux: "8829a24d8188f6655278791d3f722e05a02652a7e81943e101035460bd584825"
end

depends_on "node"

def install
system "npm", "install", *Language::Node.std_npm_install_args(libexec)
(bin/"mongosh").write_env_script libexec/"bin/mongosh", PATH: "#{Formula["node"].opt_bin}:$PATH"
system "npm", "install", *std_npm_args
bin.install_symlink Dir["#{libexec}/bin/*"]
end

test do
Expand Down

0 comments on commit 24d4baf

Please sign in to comment.