<commit_before>class Hspell < Formula
  desc "Free Hebrew linguistic project"
  homepage "http://hspell.ivrix.org.il/"
  url "http://hspell.ivrix.org.il/hspell-1.4.tar.gz"
  sha256 "7310f5d58740d21d6d215c1179658602ef7da97a816bc1497c8764be97aabea3"

  livecheck do
    url "http://hspell.ivrix.org.il/download.html"
    regex(/href=.*?hspell[._-]v?(\d+(?:\.\d+)+)\.t/i)
  end

  bottle do
    rebuild 1
    sha256 arm64_big_sur: "421fdc3ab5d0ebde258ce7bdb235d2b50144966a27a74cbbe5c607dff0984c7f"
    sha256 big_sur:       "426c87d91350f33392c862296b5d1b0081bc953adae5c04a9769ebb2a626213f"
    sha256 catalina:      "a0406d5a4d5adefa40b5e820510a9b7f461fcea6a61112103c112775fff49ae8"
    sha256 mojave:        "32e8037e9d494241b975c7558635456991285d53c9bbc89005cd6c86744f30e3"
  end

  depends_on "autoconf" => :build

  # hspell was built for linux and compiles a .so shared library, to comply with macOS
  # standards this patch creates a .dylib instead
  patch :p0 do
    url "https://raw.githubusercontent.com/Homebrew/formula-patches/85fa66a9/hspell/1.3.patch"
    sha256 "63cc1bc753b1062d1144dcdd959a0a8f712b8872dce89e54ddff2d24f2ca2065"
  end

  def install
    ENV.deparallelize<commit_msg>hspell: only apply patch on macOS (#81994)<commit_after>class Hspell < Formula
  desc "Free Hebrew linguistic project"
  homepage "http://hspell.ivrix.org.il/"
  url "http://hspell.ivrix.org.il/hspell-1.4.tar.gz"
  sha256 "7310f5d58740d21d6d215c1179658602ef7da97a816bc1497c8764be97aabea3"
  license "AGPL-3.0-only"

  livecheck do
    url "http://hspell.ivrix.org.il/download.html"
    regex(/href=.*?hspell[._-]v?(\d+(?:\.\d+)+)\.t/i)
  end

  bottle do
    rebuild 1
    sha256 arm64_big_sur: "421fdc3ab5d0ebde258ce7bdb235d2b50144966a27a74cbbe5c607dff0984c7f"
    sha256 big_sur:       "426c87d91350f33392c862296b5d1b0081bc953adae5c04a9769ebb2a626213f"
    sha256 catalina:      "a0406d5a4d5adefa40b5e820510a9b7f461fcea6a61112103c112775fff49ae8"
    sha256 mojave:        "32e8037e9d494241b975c7558635456991285d53c9bbc89005cd6c86744f30e3"
  end

  depends_on "autoconf" => :build

  uses_from_macos "zlib"

  on_macos do
    # hspell was built for linux and compiles a .so shared library, to comply with macOS
    # standards this patch creates a .dylib instead
    patch :p0 do
      url "https://raw.githubusercontent.com/Homebrew/formula-patches/85fa66a9/hspell/1.3.patch"
      sha256 "63cc1bc753b1062d1144dcdd959a0a8f712b8872dce89e54ddff2d24f2ca2065"
    end
  end

  def install
    ENV.deparallelize
{'fraction_non_alphanumeric': 0.09149021174590491, 'fraction_numerical': 0.22572912504994008, 'mean_word_length': 4.327659574468085, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 2, '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': '2309079', 'n_tokens_mistral': 1403, 'n_tokens_neox': 1125, 'n_words': 158}