<commit_before>class Smartypants < Formula
  desc "Typography prettifier"
  homepage "https://daringfireball.net/projects/smartypants/"
  url "https://daringfireball.net/projects/downloads/SmartyPants_1.5.1.zip"
  sha256 "2813a12d8dd23f091399195edd7965e130103e439e2a14f298b75b253616d531"

  bottle do
    sha256 cellar: :any_skip_relocation, all: "a1af00dbd1e4d6d42c6251fc9ca0cd36cce3370a9321f183e7f96a5bdebf8c6d"
  end

  def install
    bin.install "SmartyPants.pl" => "smartypants"
  end

  test do
    assert_equal "&#8220;Give me a beer&#8221;, said Mike O&#8217;Connor",
      pipe_output("#{bin}/smartypants",
                  %q("Give me a beer", said Mike O'Connor), 0)
  end
end<commit_msg>smartypants: add livecheck<commit_after>class Smartypants < Formula
  desc "Typography prettifier"
  homepage "https://daringfireball.net/projects/smartypants/"
  url "https://daringfireball.net/projects/downloads/SmartyPants_1.5.1.zip"
  sha256 "2813a12d8dd23f091399195edd7965e130103e439e2a14f298b75b253616d531"

  livecheck do
    url :homepage
    regex(/href=.*?SmartyPants[._-]v?(\d+(?:\.\d+)+)\.zip/i)
  end

  bottle do
    sha256 cellar: :any_skip_relocation, all: "a1af00dbd1e4d6d42c6251fc9ca0cd36cce3370a9321f183e7f96a5bdebf8c6d"
  end

  def install
    bin.install "SmartyPants.pl" => "smartypants"
  end

  test do
    assert_equal "&#8220;Give me a beer&#8221;, said <NAME>&#8217;Connor",
      pipe_output("#{bin}/smartypants",
                  %q("Give me a beer", said <NAME>), 0)
  end
end
{'fraction_non_alphanumeric': 0.11862160371106693, 'fraction_numerical': 0.1365142478462558, 'mean_word_length': 4.3736654804270465, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, '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': '5750929', 'n_tokens_mistral': 735, 'n_tokens_neox': 617, 'n_words': 99}