<commit_before>class Sccache < Formula
  desc "Used as a compiler wrapper and avoids compilation when possible"
  homepage "https://github.com/mozilla/sccache"
  url "https://github.com/mozilla/sccache/archive/v0.3.0.tar.gz"
  sha256 "26585447d07f67d0336125816680a2a5f7381065a03de3fd423a3b5c41eb637c"
  license "Apache-2.0"
  head "https://github.com/mozilla/sccache.git", branch: "master"

  bottle do
    rebuild 1
    sha256 cellar: :any_skip_relocation, arm64_ventura:  "d528f930c12552dc388d49750ba12be7dc92e3c20faa5b1da740aa4e5cafe7b8"
    sha256 cellar: :any_skip_relocation, arm64_monterey: "03a2718de73604db1bb56de5d585fb61b5d6d2c8a7eb16c066124cd3d476bd23"
    sha256 cellar: :any_skip_relocation, arm64_big_sur:  "c13133e66ad27fb4bfc33cdfec0b567c30bf198582e6efb0b7531f598eef6d80"
    sha256 cellar: :any_skip_relocation, monterey:       "ae8579e33a6b89749bf11d7853911ad09e061e442a580f6f842afed2b31bd99e"
    sha256 cellar: :any_skip_relocation, big_sur:        "f029209a8e6c5621a9470e77f5d262aa90550b5a8eae847268dbc8fcf4da84d0"
    sha256 cellar: :any_skip_relocation, catalina:       "1d01fc0f2cf10b9d70836ecf04b63f88e118ee7e5aae12db60a22b1a7e923299"
    sha256 cellar: :any_skip_relocation, x86_64_linux:   "f216377a2f2f7264425125ba4e355595742c1335c3844930493dd4737a4f4c0d"
  end

  depends_on "rust" => :build

  on_linux do
    depends_on "openssl@3" # Uses Secure Transport on macOS
  end

  def install
    # Ensure that the `openssl` crate picks up the intended library.
    # https://crates.io/crates/openssl#manual-configuration
    ENV["OPENSSL_DIR"] = Formula["openssl@3"].opt_prefix if OS.linux?

    system "cargo", "install", "--features", "all", *std_cargo_args
  end

  test do
    (testpath/"hello.c").write <<~EOS
      #include <stdio.h>
      int main() {
        puts("Hello, world!");
        return 0;
      }
    EOS
    system "#{bin}/sccache", "cc", "hello.c", "-o", "hello-c"
    assert_equal "Hello, world!", shell_output("./hello-c").chomp
  end
end
<commit_msg>sccache 0.3.1<commit_after>class Sccache < Formula
  desc "Used as a compiler wrapper and avoids compilation when possible"
  homepage "https://github.com/mozilla/sccache"
  url "https://github.com/mozilla/sccache/archive/v0.3.1.tar.gz"
  sha256 "7c26ef7047a66393f611172e6323756fc154799f119ee7e407f4a319735da153"
  license "Apache-2.0"
  head "https://github.com/mozilla/sccache.git", branch: "master"

  bottle do
    rebuild 1
    sha256 cellar: :any_skip_relocation, arm64_ventura:  "d528f930c12552dc388d49750ba12be7dc92e3c20faa5b1da740aa4e5cafe7b8"
    sha256 cellar: :any_skip_relocation, arm64_monterey: "03a2718de73604db1bb56de5d585fb61b5d6d2c8a7eb16c066124cd3d476bd23"
    sha256 cellar: :any_skip_relocation, arm64_big_sur:  "c13133e66ad27fb4bfc33cdfec0b567c30bf198582e6efb0b7531f598eef6d80"
    sha256 cellar: :any_skip_relocation, monterey:       "ae8579e33a6b89749bf11d7853911ad09e061e442a580f6f842afed2b31bd99e"
    sha256 cellar: :any_skip_relocation, big_sur:        "f029209a8e6c5621a9470e77f5d262aa90550b5a8eae847268dbc8fcf4da84d0"
    sha256 cellar: :any_skip_relocation, catalina:       "1d01fc0f2cf10b9d70836ecf04b63f88e118ee7e5aae12db60a22b1a7e923299"
    sha256 cellar: :any_skip_relocation, x86_64_linux:   "f216377a2f2f7264425125ba4e355595742c1335c3844930493dd4737a4f4c0d"
  end

  depends_on "rust" => :build

  on_linux do
    depends_on "openssl@3" # Uses Secure Transport on macOS
  end

  def install
    # Ensure that the `openssl` crate picks up the intended library.
    # https://crates.io/crates/openssl#manual-configuration
    ENV["OPENSSL_DIR"] = Formula["openssl@3"].opt_prefix if OS.linux?

    system "cargo", "install", "--features", "all", *std_cargo_args
  end

  test do
    (testpath/"hello.c").write <<~EOS
      #include <stdio.h>
      int main() {
        puts("Hello, world!");
        return 0;
      }
    EOS
    system "#{bin}/sccache", "cc", "hello.c", "-o", "hello-c"
    assert_equal "Hello, world!", shell_output("./hello-c").chomp
  end
end

{'fraction_non_alphanumeric': 0.1, 'fraction_numerical': 0.1855, 'mean_word_length': 4.781791907514451, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 7, 'https://': 8, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7203600', 'n_tokens_mistral': 2068, 'n_tokens_neox': 1664, 'n_words': 257}