<commit_before>require 'formula'

# My god! 20,000 files?!
# TODO trim that a bit? Seems crazy.

class Jruby < Formula
  url 'http://jruby.kenai.com/downloads/1.4.0/jruby-src-1.4.0.tar.gz'
  homepage 'http://www.jruby.org'
  md5 'a363b6c2ea24f0ef8df478c93ac8cc59'

  def install
    Dir.chdir 'bin' do
      FileUtils.rm Dir['*.bat']
      FileUtils.rm Dir['*.exe']
      FileUtils.rm Dir['*.dll']
      Dir['*'].each do |file|
        FileUtils.mv file, "j#{file}" unless file.match /^[j_]/
      end
    end
    
    # Only keep the MacOSX native libraries
    Dir.chdir 'lib/native' do
      Dir['*'].each do |file|
        FileUtils.rm_rf file unless file == 'darwin'
      end
    end

    prefix.install Dir['*']
  end
end
<commit_msg>The jruby-src doesn't seem to work with an installation like this, but the -bin does<commit_after>require 'formula'

# My god! 20,000 files?!
# TODO trim that a bit? Seems crazy.

class Jruby < Formula
  url 'http://jruby.kenai.com/downloads/1.4.0/jruby-bin-1.4.0.tar.gz'
  homepage 'http://www.jruby.org'
  md5 'f37322c18e9134e91e064aebb4baa4c7'

  def install
    Dir.chdir 'bin' do
      FileUtils.rm Dir['*.bat']
      FileUtils.rm Dir['*.exe']
      FileUtils.rm Dir['*.dll']
      Dir['*'].each do |file|
        FileUtils.mv file, "j#{file}" unless file.match /^[j_]/
      end
    end
    
    # Only keep the MacOSX native libraries
    Dir.chdir 'lib/native' do
      Dir['*'].each do |file|
        FileUtils.rm_rf file unless file == 'darwin'
      end
    end

    prefix.install Dir['*']
  end
end

{'fraction_non_alphanumeric': 0.1442369607211848, 'fraction_numerical': 0.038634900193174504, 'mean_word_length': 2.5560640732265445, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, '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': '3549976', 'n_tokens_mistral': 626, 'n_tokens_neox': 581, 'n_words': 148}