<commit_before>require_relative 'config/environment'
require 'wukong-deploy/tasks'

Dir[File.join(File.dirname(__FILE__), "lib/tasks/**/*.rb")].each { |path| require(path) }

require 'rspec/core/rake_task'
RSpec::Core::RakeTask.new(:rspec)

dependency_space :dependency do

  task :gems do
    BuildHelper.install_gem_dependency('multi_json', '1.0.4')
    BuildHelper.install_gem_dependency 'simple_classifier'
  end

end

dependency_space :configure => :dependency do
  
  task :flume_conf do
    ext_dirs = BuildHelper.parse_property_file
    ext_dirs.unshift(BuildHelper.path_to(:ruby_root).to_s).uniq!
    BuildHelper.write_property_file(ext_dirs)
  end
  
end

dependency_space :deploy => :configure do

  task :gem_jar do
    jar_name = 'gem-dependencies.jar'
    gem_path = BuildHelper.path_to(:vendor).join('gem')
    sh "jar cf #{BuildHelper.path_to(:vendor).join(jar_name)} -C #{gem_path} ." if gem_path.exist?
    src      = BuildHelper.path_to(:vendor).join(jar_name)
    dest     = BuildHelper.path_to(:flume_lib).join(jar_name)
    FileUtils.cp(src, dest) if src.exist?    
  end
  
  task(:maven){ sh "mvn package -Dflume.libdir=#{BuildHelper.path_to(:flume_lib)} clean" }
   
end

task :default => :rspec
<commit_msg>update to rakefile<commit_after>require_relative 'config/environment'
require 'wukong-deploy/tasks'
require 'rake'

require 'rspec/core/rake_task'
RSpec::Core::RakeTask.new(:spec)

Wukong::Deploy.require_recursive('lib/tasks')

task :default => :spec

{'fraction_non_alphanumeric': 0.1347708894878706, 'fraction_numerical': 0.0020215633423180594, 'mean_word_length': 4.987903225806452, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, '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': '7184278', 'n_tokens_mistral': 546, 'n_tokens_neox': 528, 'n_words': 89}