<commit_before>#!/bin/sh

# If you've non-standard directories, set these
#ACLOCAL_DIR=
#GETTEXT_DIR=

ACLOCAL="aclocal -I ."
if test "$ACLOCAL_DIR" != ""; then
  ACLOCAL="$ACLOCAL -I $ACLOCAL_DIR"
fi
export ACLOCAL

for dir in $GETTEXT_DIR /usr/share/gettext /usr/local/share/gettext; do
  if test -f $dir/config.rpath; then
    /bin/cp -f $dir/config.rpath .
    break
  fi
done

if test ! -f doc/wiki/Authentication.txt; then
  cd doc
  wget http://www.dovecot.org/tmp/wiki2-export.tar.gz
  tar xzf wiki2-export.tar.gz
  mv wiki2-export/*.txt wiki/
  rm -rf wiki2-export wiki2-export.tar.gz
  cd ..
fi

cd doc/wiki
cp -f Makefile.am.in Makefile.am<commit_msg>autogen.sh: If wiki docs can't be downloaded/uncompressed, fail early.<commit_after>#!/bin/sh

# If you've non-standard directories, set these
#ACLOCAL_DIR=
#GETTEXT_DIR=

ACLOCAL="aclocal -I ."
if test "$ACLOCAL_DIR" != ""; then
  ACLOCAL="$ACLOCAL -I $ACLOCAL_DIR"
fi
export ACLOCAL

for dir in $GETTEXT_DIR /usr/share/gettext /usr/local/share/gettext; do
  if test -f $dir/config.rpath; then
    /bin/cp -f $dir/config.rpath .
    break
  fi
done

if test ! -f doc/wiki/Authentication.txt; then
  cd doc
  wget http://www.dovecot.org/tmp/wiki2-export.tar.gz
  tar xzf wiki2-export.tar.gz
  if [ $? != 0 ]; then
    echo "Failed to uncompress wiki docs"
    exit
  fi
  mv wiki2-export/*.txt wiki/
  rm -rf wiki2-export wiki2-export.tar.gz
  cd ..
fi

cd doc/wiki
cp -f Makefile.am.in Makefile.am
{'fraction_non_alphanumeric': 0.13493150684931507, 'fraction_numerical': 0.007534246575342466, 'mean_word_length': 3.138810198300283, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 1, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3563167', 'n_tokens_mistral': 599, 'n_tokens_neox': 573, 'n_words': 150}