<commit_before>from rpm2scl.decorators import matches
from rpm2scl.transformers.transformer import Transformer

class RubyTransformer(Transformer):
    def __init__(self, spec, options = None):
        super(RubyTransformer, self).__init__(spec, options)

    @matches(r'gem (?:(?:install)|(?:unpack)|(?:build))', one_line = False)
    @matches(r'testrb ', one_line = False)
    @matches(r'testrb2 ', one_line = False)
    @matches(r'(?<!-)rspec ', one_line = False) # avoid matching stuff like 'rubygem-rspec ' here
    def handle_ruby_specific_commands(self, pattern, text):
        print pattern.search(text).groups()
        return self.sclize_all_commands(pattern, text)<commit_msg>Remove forgotten debug print<commit_after>from rpm2scl.decorators import matches
from rpm2scl.transformers.transformer import Transformer

class RubyTransformer(Transformer):
    def __init__(self, spec, options = None):
        super(RubyTransformer, self).__init__(spec, options)

    @matches(r'gem (?:(?:install)|(?:unpack)|(?:build))', one_line = False)
    @matches(r'testrb ', one_line = False)
    @matches(r'testrb2 ', one_line = False)
    @matches(r'(?<!-)rspec ', one_line = False) # avoid matching stuff like 'rubygem-rspec ' here
    def handle_ruby_specific_commands(self, pattern, text):
        return self.sclize_all_commands(pattern, text)
{'fraction_non_alphanumeric': 0.13382899628252787, 'fraction_numerical': 0.0044609665427509295, 'mean_word_length': 5.118181818181818, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, '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': '7530293', 'n_tokens_mistral': 431, 'n_tokens_neox': 417, 'n_words': 92}