<commit_before>require 'formula'

class GitSubtree <Formula
  homepage 'http://github.com/apenwarr/git-subtree'
  head 'git://github.com/apenwarr/git-subtree.git',
        :tag => 'c00d1d11688dc02f066196ed18783effdb7767ab'

  # Not depending on git because people might have it
  # installed through another means

  def install
    bin.install "git-subtree.sh" => "git-subtree"
  end
end<commit_msg>git-subtree: add `--build-docs` option<commit_after>require 'formula'

class GitSubtree <Formula
  homepage 'http://github.com/apenwarr/git-subtree'
  head 'git://github.com/apenwarr/git-subtree.git',
        :tag => 'v0.3'

  def options
    [
      ['--build-docs', "Build man pages using asciidoc and xmlto"]
    ]
  end

  if ARGV.include? '--build-docs'
    # these are needed to build man pages
    depends_on 'asciidoc'
    depends_on 'xmlto'
  end

  # Not depending on git because people might have it
  # installed through another means

  def install
    if ARGV.include? '--build-docs'
      system "make doc"
      man1.install "git-subtree.1"
    else
      doc.install "git-subtree.txt"
    end
    bin.install "git-subtree.sh" => "git-subtree"
  end
end
{'fraction_non_alphanumeric': 0.11719418306244654, 'fraction_numerical': 0.02480752780153978, 'mean_word_length': 3.0484429065743943, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 2}, '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': '3602504', 'n_tokens_mistral': 433, 'n_tokens_neox': 411, 'n_words': 102}