<commit_before>#!/usr/bin/env bash

cmd="./manage.py makemessages --no-wrap --no-location --no-obsolete $@"
echo "${cmd}"
${cmd}
echo "Done."
echo
echo "Checking for changes in .po files..."
git diff --ignore-matching-lines=POT-Creation-Date --exit-code -- '***.po'

diff_result=$?
test $diff_result -eq 0 && echo "No changed messages found."
echo
exit $diff_result<commit_msg>Apply suggestions from code review<commit_after>#!/usr/bin/env bash
set -e
cmd="./manage.py"
args=(makemessages --no-wrap --no-location --no-obsolete "${@}")
echo "${cmd} ${args[*]}"
${cmd} "${args[@]}"
echo "Done."
echo
echo "Checking for changes in .po files..."
git diff --ignore-matching-lines=POT-Creation-Date --exit-code -- '***.po'

diff_result=$?
test $diff_result -eq 0 && echo "No changed messages found."
echo
exit $diff_result
{'fraction_non_alphanumeric': 0.20098039215686275, 'fraction_numerical': 0.0024509803921568627, 'mean_word_length': 4.074534161490683, 'pattern_counts': {'":': 0, '<': 3, '<?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': '4390903', 'n_tokens_mistral': 293, 'n_tokens_neox': 279, 'n_words': 83}