<commit_before>class Utf8proc < Formula
  desc "Clean C library for processing UTF-8 Unicode data"
  # Canonical homepage is https://julialang.org/utf8proc
  homepage "https://github.com/JuliaStrings/utf8proc"
  url "https://github.com/JuliaStrings/utf8proc/archive/v2.2.0.tar.gz"
  sha256 "3f8fd1dbdb057ee5ba584a539d5cd1b3952141c0338557cb0bdf8cb9cfed5dbf"

  bottle do
    cellar :any
    sha256 "cdcd5132f9ae0bebe232c59e76d66f4a0cb6a4a26f37c94041a78fd214484348" => :high_sierra
    sha256 "dda62c99b48421dee34963e3be55e1db932227b21b4ab5005f268ff4e4f187c3" => :sierra
    sha256 "f7065fb123f7d5946ed5c55784d14069c54c1cef02982f28921018307cb86a99" => :el_capitan
  end

  def install
    system "make", "install", "prefix=#{prefix}"
  end

  test do
    (testpath/"test.c").write <<~EOS
      #include <string.h>
      #include <utf8proc.h><commit_msg>utf8proc: update 2.2.0 bottle for Linuxbrew.<commit_after>class Utf8proc < Formula
  desc "Clean C library for processing UTF-8 Unicode data"
  # Canonical homepage is https://julialang.org/utf8proc
  homepage "https://github.com/JuliaStrings/utf8proc"
  url "https://github.com/JuliaStrings/utf8proc/archive/v2.2.0.tar.gz"
  sha256 "3f8fd1dbdb057ee5ba584a539d5cd1b3952141c0338557cb0bdf8cb9cfed5dbf"

  bottle do
    cellar :any
    sha256 "cdcd5132f9ae0bebe232c59e76d66f4a0cb6a4a26f37c94041a78fd214484348" => :high_sierra
    sha256 "dda62c99b48421dee34963e3be55e1db932227b21b4ab5005f268ff4e4f187c3" => :sierra
    sha256 "f7065fb123f7d5946ed5c55784d14069c54c1cef02982f28921018307cb86a99" => :el_capitan
    sha256 "cd274d13716f4f34dc1a79910a8874b7ffe0fd4241156825637a7b4b72c0214a" => :x86_64_linux
  end

  def install
    system "make", "install", "prefix=#{prefix}"
  end

  test do
    (testpath/"test.c").write <<~EOS
      #include <string.h>
      #include <utf8proc.h>
{'fraction_non_alphanumeric': 0.09573304157549234, 'fraction_numerical': 0.22592997811816193, 'mean_word_length': 5.158249158249158, 'pattern_counts': {'":': 0, '<': 13, '<?xml version=': 0, '>': 14, 'https://': 6, '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': '1831621', 'n_tokens_mistral': 1004, 'n_tokens_neox': 794, 'n_words': 109}