<commit_before>require "language/node"

class VercelCli < Formula
  desc "Command-line interface for Vercel"
  homepage "https://vercel.com/home"
  url "https://registry.npmjs.org/vercel/-/vercel-28.4.11.tgz"
  sha256 "704aabf5f4c93385faa48781a7f6c0dbbddeb5cb0e48325ab99939b117fd5f0b"
  license "Apache-2.0"

  bottle do
    sha256 cellar: :any_skip_relocation, arm64_monterey: "cc9f0fca41fe76aa6a55638cbdf7a53292075dfc2d07cb1f96d4bc2c1dd1e022"
    sha256 cellar: :any_skip_relocation, arm64_big_sur:  "cc9f0fca41fe76aa6a55638cbdf7a53292075dfc2d07cb1f96d4bc2c1dd1e022"
    sha256 cellar: :any_skip_relocation, monterey:       "7506e57120c38af899bad47765d995d4502e0cab4eda21895f64dc1245aff513"
    sha256 cellar: :any_skip_relocation, big_sur:        "9ba322180b8c3d1cab59c931277c2074dda2026f6ff6bf6dc9c365bde64e5c42"
    sha256 cellar: :any_skip_relocation, catalina:       "9ba322180b8c3d1cab59c931277c2074dda2026f6ff6bf6dc9c365bde64e5c42"
    sha256 cellar: :any_skip_relocation, x86_64_linux:   "d5170742b822ba5e6a963c60eb90acfd6830d8f1799f0fbaf00e2212fa51e99e"
  end

  depends_on "node"

  on_macos do
    depends_on "macos-term-size"
  end

  def install
    rm Dir["dist/{*.exe,xsel}"]
    inreplace "dist/index.js", "= getUpdateCommand",
                               "= async()=>'brew upgrade vercel-cli'"
    system "npm", "install", *Language::Node.std_npm_install_args(libexec)
    bin.install_symlink Dir["#{libexec}/bin/*"]

    dist_dir = libexec/"lib/node_modules/vercel/dist"
    rm_rf dist_dir/"term-size"

    if OS.mac?
      # Replace the vendored pre-built term-size with one we build ourselves
      ln_sf (Formula["macos-term-size"].opt_bin/"term-size").relative_path_from(dist_dir), dist_dir
    end
  end

  test do
    system "#{bin}/vercel", "init", "jekyll"
    assert_predicate testpath/"jekyll/_config.yml", :exist?, "_config.yml must exist"
    assert_predicate testpath/"jekyll/README.md", :exist?, "README.md must exist"
  end
end
<commit_msg>vercel-cli: update 28.4.11 bottle.<commit_after>require "language/node"

class VercelCli < Formula
  desc "Command-line interface for Vercel"
  homepage "https://vercel.com/home"
  url "https://registry.npmjs.org/vercel/-/vercel-28.4.11.tgz"
  sha256 "704aabf5f4c93385faa48781a7f6c0dbbddeb5cb0e48325ab99939b117fd5f0b"
  license "Apache-2.0"

  bottle do
    sha256 cellar: :any_skip_relocation, arm64_monterey: "39d792b31da4c048e79ab43367f24b9453cab1edac76ecbf5ae2a8920984b060"
    sha256 cellar: :any_skip_relocation, arm64_big_sur:  "39d792b31da4c048e79ab43367f24b9453cab1edac76ecbf5ae2a8920984b060"
    sha256 cellar: :any_skip_relocation, monterey:       "64d84d9acc8f3586a200aabdc69ebb50120e028338e4eb9eb73a000393053a6e"
    sha256 cellar: :any_skip_relocation, big_sur:        "d48f58626efacfb5f0bd4dd48f3f262d684fc99339e31164c4c68cbc8d2f14ab"
    sha256 cellar: :any_skip_relocation, catalina:       "d48f58626efacfb5f0bd4dd48f3f262d684fc99339e31164c4c68cbc8d2f14ab"
    sha256 cellar: :any_skip_relocation, x86_64_linux:   "ebf6f858c7e884ae1cbde2941aa805a3c54a1fd9d503f4304d59a8a65f90b7a3"
  end

  depends_on "node"

  on_macos do
    depends_on "macos-term-size"
  end

  def install
    rm Dir["dist/{*.exe,xsel}"]
    inreplace "dist/index.js", "= getUpdateCommand",
                               "= async()=>'brew upgrade vercel-cli'"
    system "npm", "install", *Language::Node.std_npm_install_args(libexec)
    bin.install_symlink Dir["#{libexec}/bin/*"]

    dist_dir = libexec/"lib/node_modules/vercel/dist"
    rm_rf dist_dir/"term-size"

    if OS.mac?
      # Replace the vendored pre-built term-size with one we build ourselves
      ln_sf (Formula["macos-term-size"].opt_bin/"term-size").relative_path_from(dist_dir), dist_dir
    end
  end

  test do
    system "#{bin}/vercel", "init", "jekyll"
    assert_predicate testpath/"jekyll/_config.yml", :exist?, "_config.yml must exist"
    assert_predicate testpath/"jekyll/README.md", :exist?, "README.md must exist"
  end
end

{'fraction_non_alphanumeric': 0.10233844606487302, 'fraction_numerical': 0.15061604224289665, 'mean_word_length': 4.650568181818182, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 4, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4293251', 'n_tokens_mistral': 1968, 'n_tokens_neox': 1646, 'n_words': 233}