<commit_before>require 'yaml'

class Rrod::Engine < ::Rails::Engine

  initializer "rrod.rails.configuration" do |app|
    begin
      nodes = YAML.load_file(Rails.root.join('config', 'rrod.yml'))[Rails.env]
      Rrod.configuration.nodes = nodes 
    rescue Errno::ENOENT => _e
      message = "Missing config/rrod.yml file please run `rails generate rrod:install`"
      Rails.logger.warn message
      STDERR.puts message
    end
  end
<commit_msg>erb config files<commit_after>require 'yaml'
require 'erb'

class Rrod::Engine < ::Rails::Engine

  initializer "rrod.rails.configuration" do |app|
    begin
      nodes = YAML.load_file(ERB.new(Rails.root.join('config', 'rrod.yml')).result)[Rails.env]
      Rrod.configuration.nodes = nodes 
    rescue Errno::ENOENT => _e
      message = "Missing config/rrod.yml file please run `rails generate rrod:install`"
      Rails.logger.warn message
      STDERR.puts message
    end
  end

{'fraction_non_alphanumeric': 0.11978609625668449, 'fraction_numerical': 0.0, 'mean_word_length': 3.478468899521531, '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': '6467020', 'n_tokens_mistral': 322, 'n_tokens_neox': 308, 'n_words': 70}