<commit_before>class Libltc < Formula
  desc "POSIX-C Library for handling Linear/Logitudinal Time Code (LTC)"
  homepage "https://x42.github.io/libltc/"
  url "https://github.com/x42/libltc/releases/download/v1.3.0/libltc-1.3.0.tar.gz"
  sha256 "aab1de052bc61fbac6ea66d88f04e95b7d5faa1ef297b95ea6a1a548c87dee5c"

  bottle do
    cellar :any
    sha256 "28d1c8f3eefb0397ee41e69bbdfef98088e1995cab468ebf8c5a6acbc55d21cf" => :mojave
    sha256 "ede5ce5a9de5f89bc42c9201da577af1249415435cbab06b5abcb51577ef6902" => :high_sierra
    sha256 "5ce9e5d2072877c2d7ba32260047aa900b0918a796bd07ecc069c098d0763a6c" => :sierra
    sha256 "39c5b5eae78f0abb51a5ac965f9e3f89bf831861ca88347b170f4fd4a9562b6e" => :el_capitan
    sha256 "9e42898755bb3312b42cd61a28e658288a3282801d401f771cfb6236ba4a08aa" => :yosemite
  end

  def install
    system "./configure", "--prefix=#{prefix}"
    system "make", "install"
  end

  test do
    (testpath/"test.c").write <<~EOS
      // stripped-down copy of:
      // https://raw.githubusercontent.com/x42/libltc/87d45b3/tests/example_encode.c
      #include <stdio.h>
      #include <stdlib.h>
      #include <string.h>
      #include <ltc.h>

      int main(int argc, char **argv) {<commit_msg>libltc 1.3.1<commit_after>class Libltc < Formula
  desc "POSIX-C Library for handling Linear/Logitudinal Time Code (LTC)"
  homepage "https://x42.github.io/libltc/"
  url "https://github.com/x42/libltc/releases/download/v1.3.1/libltc-1.3.1.tar.gz"
  sha256 "50e63eb3b767151bc0159a3cc5d426d03a42fd69029bc9b3b7c346555f4b709c"

  bottle do
    cellar :any
    sha256 "28d1c8f3eefb0397ee41e69bbdfef98088e1995cab468ebf8c5a6acbc55d21cf" => :mojave
    sha256 "ede5ce5a9de5f89bc42c9201da577af1249415435cbab06b5abcb51577ef6902" => :high_sierra
    sha256 "5ce9e5d2072877c2d7ba32260047aa900b0918a796bd07ecc069c098d0763a6c" => :sierra
    sha256 "39c5b5eae78f0abb51a5ac965f9e3f89bf831861ca88347b170f4fd4a9562b6e" => :el_capitan
    sha256 "9e42898755bb3312b42cd61a28e658288a3282801d401f771cfb6236ba4a08aa" => :yosemite
  end

  def install
    system "./configure", "--prefix=#{prefix}"
    system "make", "install"
  end

  test do
    (testpath/"test.c").write <<~EOS
      // stripped-down copy of:
      // https://raw.githubusercontent.com/x42/libltc/87d45b3/tests/example_encode.c
      #include <stdio.h>
      #include <stdlib.h>
      #include <string.h>
      #include <ltc.h>

      int main(int argc, char **argv) {
{'fraction_non_alphanumeric': 0.11006160164271048, 'fraction_numerical': 0.22012320328542095, 'mean_word_length': 4.342105263157895, 'pattern_counts': {'":': 0, '<': 17, '<?xml version=': 0, '>': 21, 'https://': 6, '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': '2081229', 'n_tokens_mistral': 1360, 'n_tokens_neox': 1086, 'n_words': 137}