<commit_before>require "digest/sha1"
module Helper
  def path
    @@path ||= "/tmp/#{Digest::SHA1.hexdigest(Time.now.to_s)}"
  end

  def setup
    `mkdir #{path} && cd #{path} && git init`
  end

  def teardown
    `rm -rf #{path}`
  end

  #
  # @hash String A commit hash
  # @return Array<String> A list of files
  #<commit_msg>Create tmp git folders for tests using Dir.mktmpdir instead of UNIXs mkdir<commit_after>require "tmpdir"
module Helper
  def path
    @path ||= Dir.mktmpdir
  end

  def setup
    `cd #{path} && git init`
  end

  def teardown
    `rm -rf #{path}`
  end

  #
  # @hash String A commit hash
  # @return Array<String> A list of files
  #
{'fraction_non_alphanumeric': 0.12443778110944528, 'fraction_numerical': 0.0029985007496251873, 'mean_word_length': 2.9064327485380117, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, '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': '4403135', 'n_tokens_mistral': 254, 'n_tokens_neox': 244, 'n_words': 79}