<commit_before>#!/bin/bash

set -xe

ROOT=$(dirname $(realpath $0))/../..
SPEC=$ROOT/build/tuna.spec
OUTDIR=$ROOT/dist

NUMPY=numpy-1.13.0+mkl-cp35-cp35m-win_amd64.whl
SCIPY=scipy-0.19.1-cp35-cp35m-win_amd64.whl

if test ! \( -f $NUMPY -a -f $SCIPY \); then
  cat<<EOF
Download following 2 files:
  * $NUMPY
  * $SCIPY
from:
  http://www.lfd.uci.edu/~gohlke/pythonlibs/
and place these files into:
  $(pwd)
EOF
  exit 1
fi


export WINEPREFIX=$(pwd)/wine
rm -rf $WINEPREFIX python-msi build dist


WINETRICKS_URL=https://raw.githubusercontent.com/Winetricks/winetricks/master/src/winetricks
test ! -f winetricks && curl -LO $WINETRICKS_URL
bash winetricks win8


PYTHON_EXE_URL=https://www.python.org/ftp/python/3.5.3/python-3.5.3-amd64-webinstall.exe
PYTHON_EXE=${PYTHON_EXE_URL##*/}
test ! -f $PYTHON_EXE && curl -LO $PYTHON_EXE_URL

<commit_msg>Check required files before "set -xe"<commit_after>#!/bin/bash

ROOT=$(dirname $(realpath $0))/../..
SPEC=$ROOT/build/tuna.spec
OUTDIR=$ROOT/dist

NUMPY=numpy-1.13.0+mkl-cp35-cp35m-win_amd64.whl
SCIPY=scipy-0.19.1-cp35-cp35m-win_amd64.whl

if test ! \( -f $NUMPY -a -f $SCIPY \); then
  cat<<EOF
Download following 2 files:
  * $NUMPY
  * $SCIPY
from:
  http://www.lfd.uci.edu/~gohlke/pythonlibs/
and place these files into:
  $(pwd)
EOF
  exit 1
fi

set -xe

export WINEPREFIX=$(pwd)/wine
rm -rf $WINEPREFIX python-msi build dist


WINETRICKS_URL=https://raw.githubusercontent.com/Winetricks/winetricks/master/src/winetricks
test ! -f winetricks && curl -LO $WINETRICKS_URL
bash winetricks win8


PYTHON_EXE_URL=https://www.python.org/ftp/python/3.5.3/python-3.5.3-amd64-webinstall.exe
PYTHON_EXE=${PYTHON_EXE_URL##*/}
test ! -f $PYTHON_EXE && curl -LO $PYTHON_EXE_URL


{'fraction_non_alphanumeric': 0.16230366492146597, 'fraction_numerical': 0.03723094822571262, 'mean_word_length': 4.029239766081871, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 3, 'https://': 4, 'lorem ipsum': 0, 'www.': 4, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1962213', 'n_tokens_mistral': 818, 'n_tokens_neox': 771, 'n_words': 131}