<commit_before>#!/bin/sh
# Copyright (C) 2008 <NAME> <<EMAIL>>
grep 'RegExpr' * | grep --color=auto -E 'String=\s*(["'"'"'])(%?([a-zA-Z"'"'"'#_!/=:;<>-]|\\[\\\]\[()\{\}.$^+*?]|[()|]|&(amp|gt|lt|apos|quot);)|[0-9])*%?\1'
<commit_msg>- Split regex to several lines to make it more readable - Add support for (\^(\\s[*+]?)?)? after the opening quote character<commit_after>#!/bin/sh
# Copyright (C) 2008 <NAME> <<EMAIL>>
grep 'RegExpr' * | grep --color=auto -E 'String=\s*(["'"'"'])'\
'(\^(\\s[*+]?)?)?'\
'('\
'%?'\
'('\
'[a-zA-Z"'"'"'#_!/=:;<>-]'\
'|\\[\\\]\[()\{\}.$^+*?]'\
'|[()|]'\
'|\(\?:'\
'|&(amp|gt|lt|apos|quot);'\
')'\
'|[0-9]'\
')*%?'\
'\1'

{'fraction_non_alphanumeric': 0.4576271186440678, 'fraction_numerical': 0.02157164869029276, 'mean_word_length': 4.038759689922481, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 11, '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': '7045921', 'n_tokens_mistral': 343, 'n_tokens_neox': 314, 'n_words': 48}