<commit_before>#---------------------------------#
#      general configuration      #
#---------------------------------#

# version format
version: 0.3.0.{build}

branches:
  only:
    - master

  except:
    - gh-pages

skip_commits:
  # Add [av skip] to commit messages to skip AppVeyor building
  # Add [ci skip] to skip Travis and AppVeyor building
  message: /\[av skip\]/ 

#---------------------------------#
#    environment configuration    #
#---------------------------------#

# http://www.appveyor.com/docs/environment-variables
# http://www.appveyor.com/docs/installed-software

init:
  - git config --global core.autocrlf input

clone_folder: c:\projects\nupic-core
clone_depth: 50

# Can't have a shallow clone because the CMake process will be
# calling into git to write the current SHA into the binaries.
shallow_clone: false

environment:
  PYTHON_ARCH: "64"
  COMPILER_FAMILY: GCC
      
  matrix:
    - PYTHON_VERSION: "2.7.9"
      PYTHONPATH: "C:\\Python27-x64"

#---------------------------------#
#       build configuration       #
#---------------------------------#

configuration: Release

cache:
  - C:\mingwpy_amd64_vc90.7z
  - C:\libpython-cp27-none-win_amd64.7z
  - C:\numpy-1.9.1+openblas-cp27-none-win_amd64.whl

install:
  - set NUPIC_DEPLOYMENT_BUILD=1

  - set REPO_DIR=c:\projects\nupic-core
  - set NUPIC_CORE_DIR=%REPO_DIR%\build\release
  - set EXT_LIBS=%REPO_DIR%\external\windows64-gcc\lib

  - set ARTIFACTS_DIR=%REPO_DIR%\build\artifacts
  - for /f %%i in ('"python ci\appveyor\parse_version.py"') do set BINDINGS_VERSION=%%i
  - echo Binding version = %BINDINGS_VERSION%

  # Reference: https://bitbucket.org/carlkl/mingw-w64-for-python/downloads/mingwpy-2015-04-readme.md
  - ps: $dwntool=New-Object System.Net.WebClient

  - ECHO "Installing MinGW-w64 for Python:"
  - ps: if (-Not (Test-Path "C:\\mingwpy_amd64_vc90.7z")) { $dwntool.DownloadFile("https://bitbucket.org/carlkl/mingw-w64-for-python/downloads/mingwpy_amd64_vc90.7z", "C:\\mingwpy_amd64_vc90.7z") }
  - 7z x C:\\mingwpy_amd64_vc90.7z -oC:\ > null

  - ECHO "Installing MinGW-w64 Python 2.7.x libs:"
  - ps: if (-Not (Test-Path "C:\\libpython-cp27-none-win_amd64.7z")) { $dwntool.DownloadFile("https://bitbucket.org/carlkl/mingw-w64-for-python/downloads/libpython-cp27-none-win_amd64.7z", "C:\\libpython-cp27-none-win_amd64.7z") }
  - 7z x C:\\libpython-cp27-none-win_amd64.7z -oC:\Python27-x64\ > null

  - set PATH=C:\mingwpy\bin;%PATH%

  # Patch up LTO plugins (only needed for certain MinGW-w64 GCC toolchains)
  #- mkdir C:\mingw64\lib\bfd-plugins
  #- cp C:\mingw64\libexec\gcc\x86_64-w64-mingw32\4.9.3\liblto_plugin-0.dll C:\mingw64\lib\bfd-plugins\liblto_plugin-0.dll

  # Install Python 2.7.x, Pip, Wheel, and NumPy
  - cd %REPO_DIR%\ci\appveyor
  - ps: .\install_python_pip.ps1

  - set PYTHONPATH=%PYTHONPATH%
  - set PATH=%PYTHONPATH%;%PYTHONPATH%\Scripts;%PATH%

  # Setup MinGW-w64 GCC as a valid distutils compiler
  - cp %REPO_DIR%\external\windows64-gcc\bin\distutils.cfg %PYTHONPATH%\Lib\distutils\distutils.cfg

  # Check that we have the expected version and architecture for Python
  - "python --version"
  - "python -c \"import struct; print(struct.calcsize('P') * 8)\""

  # Check NumPy installed correctly
  - cmd: pip list

  - cd %REPO_DIR%
  - mkdir %REPO_DIR%\build\
  - mkdir %REPO_DIR%\build\release
  - mkdir %REPO_DIR%\build\scripts

  # Remove sh.exe from the paths (CMake doesn't like it)
  - set PATH=%PATH:C:\Program Files (x86)\Git\bin;=%
  - set PATH=%PATH:C:\Program Files\Git\usr\bin;=%
  - set PATH=%PATH:C:\MinGW\msys\1.0\bin;=%

  # Fake KJ-Async and Capnp-RPC libs, not needed in Lite mode
  # http://www.cmake.org/Wiki/CmakeMingw
  - cd %REPO_DIR%\build\scripts
  - cmake -G "MinGW Makefiles" 
      -DCMAKE_BUILD_TYPE=Debug 
      -DCMAKE_INSTALL_PREFIX=%REPO_DIR%\build\release 
      -DPYTHON_LIBRARY=%PYTHONPATH%\libs\libpython27.dll.a 
      -DPYTHON_INCLUDE_DIR=%PYTHONPATH%\include 
      -DCAPNP_INCLUDE_DIRS=%REPO_DIR%\external\windows64\include 
      -DCAPNP_EXECUTABLE=%REPO_DIR%\external\windows64\bin\capnp.exe 
      -DCAPNPC_CXX_EXECUTABLE=%REPO_DIR%\external\windows64\bin\capnpc-c++.exe 
      -DLIB_KJ=%EXT_LIBS%\libkj.a 
      -DLIB_CAPNP=%EXT_LIBS%\libcapnp.a 
      -DLIB_CAPNPC=%EXT_LIBS%\libcapnp.a 
      -DCAPNP_LIB_KJ=%EXT_LIBS%\libkj.a 
      -DCAPNP_LIB_CAPNP=%EXT_LIBS%\libcapnp.a 
      -DCAPNP_LIB_KJ-ASYNC=%EXT_LIBS%\libkj.a 
      -DCAPNP_LIB_CAPNP-RPC=%EXT_LIBS%\libcapnp.a 
      -DLIB_STATIC_APR1_LOC=%EXT_LIBS%\libapr-1.a 
      -DLIB_STATIC_APRUTIL1_LOC=%EXT_LIBS%\libaprutil-1.a 
      -DLIB_STATIC_YAML_CPP_LOC=%EXT_LIBS%\libyaml-cpp.a 
      -DLIB_STATIC_YAML_LOC=%EXT_LIBS%\libyaml.a 
      -DLIB_STATIC_Z_LOC=%EXT_LIBS%\libz.a 
      %REPO_DIR%

build_script:
  - cd %REPO_DIR%\build\scripts

  - mingw32-make -f Makefile -j3
  - mingw32-make -f Makefile install | findstr /C:"Install" /I /V

  - cd %REPO_DIR%

  - python setup.py bdist_wheel --debug --compiler=mingw --nupic-core-dir=%NUPIC_CORE_DIR%
  - ps: move .\bindings\py\dist\nupic.bindings-$env:BINDINGS_VERSION-cp27-none-win_amd64.whl .

after_build:
  - mkdir %ARTIFACTS_DIR%

  # legacy binary tests
  - cd %REPO_DIR%\build\release\bin
  - cpp_region_test.exe
  - unit_tests.exe --gtest_output=xml:%ARTIFACTS_DIR%\unit_tests_report.xml"

  - ps: >-
      if ($env:APPVEYOR_REPO_COMMIT -eq "master") {<commit_msg>Verbose print on AV<commit_after>#---------------------------------#
#      general configuration      #
#---------------------------------#

# version format
version: 0.3.0.{build}

branches:
  only:
    - master

  except:
    - gh-pages

skip_commits:
  # Add [av skip] to commit messages to skip AppVeyor building
  # Add [ci skip] to skip Travis and AppVeyor building
  message: /\[av skip\]/ 

#---------------------------------#
#    environment configuration    #
#---------------------------------#

# http://www.appveyor.com/docs/environment-variables
# http://www.appveyor.com/docs/installed-software

init:
  - git config --global core.autocrlf input

clone_folder: c:\projects\nupic-core
clone_depth: 50

# Can't have a shallow clone because the CMake process will be
# calling into git to write the current SHA into the binaries.
shallow_clone: false

environment:
  PYTHON_ARCH: "64"
  COMPILER_FAMILY: GCC
      
  matrix:
    - PYTHON_VERSION: "2.7.9"
      PYTHONPATH: "C:\\Python27-x64"

#---------------------------------#
#       build configuration       #
#---------------------------------#

configuration: Release

cache:
  - C:\mingwpy_amd64_vc90.7z
  - C:\libpython-cp27-none-win_amd64.7z
  - C:\numpy-1.9.1+openblas-cp27-none-win_amd64.whl

install:
  - set NUPIC_DEPLOYMENT_BUILD=1

  - set REPO_DIR=c:\projects\nupic-core
  - set NUPIC_CORE_DIR=%REPO_DIR%\build\release
  - set EXT_LIBS=%REPO_DIR%\external\windows64-gcc\lib

  - set ARTIFACTS_DIR=%REPO_DIR%\build\artifacts
  - for /f %%i in ('"python ci\appveyor\parse_version.py"') do set BINDINGS_VERSION=%%i
  - echo Binding version = %BINDINGS_VERSION%

  # Reference: https://bitbucket.org/carlkl/mingw-w64-for-python/downloads/mingwpy-2015-04-readme.md
  - ps: $dwntool=New-Object System.Net.WebClient

  - ECHO "Installing MinGW-w64 for Python:"
  - ps: if (-Not (Test-Path "C:\\mingwpy_amd64_vc90.7z")) { $dwntool.DownloadFile("https://bitbucket.org/carlkl/mingw-w64-for-python/downloads/mingwpy_amd64_vc90.7z", "C:\\mingwpy_amd64_vc90.7z") }
  - 7z x C:\\mingwpy_amd64_vc90.7z -oC:\ > null

  - ECHO "Installing MinGW-w64 Python 2.7.x libs:"
  - ps: if (-Not (Test-Path "C:\\libpython-cp27-none-win_amd64.7z")) { $dwntool.DownloadFile("https://bitbucket.org/carlkl/mingw-w64-for-python/downloads/libpython-cp27-none-win_amd64.7z", "C:\\libpython-cp27-none-win_amd64.7z") }
  - 7z x C:\\libpython-cp27-none-win_amd64.7z -oC:\Python27-x64\ > null

  - set PATH=C:\mingwpy\bin;%PATH%

  # Patch up LTO plugins (only needed for certain MinGW-w64 GCC toolchains)
  #- mkdir C:\mingw64\lib\bfd-plugins
  #- cp C:\mingw64\libexec\gcc\x86_64-w64-mingw32\4.9.3\liblto_plugin-0.dll C:\mingw64\lib\bfd-plugins\liblto_plugin-0.dll

  # Install Python 2.7.x, Pip, Wheel, and NumPy
  - cd %REPO_DIR%\ci\appveyor
  - ps: .\install_python_pip.ps1

  - set PYTHONPATH=%PYTHONPATH%
  - set PATH=%PYTHONPATH%;%PYTHONPATH%\Scripts;%PATH%

  # Setup MinGW-w64 GCC as a valid distutils compiler
  - cp %REPO_DIR%\external\windows64-gcc\bin\distutils.cfg %PYTHONPATH%\Lib\distutils\distutils.cfg

  # Check that we have the expected version and architecture for Python
  - "python --version"
  - "python -c \"import struct; print(struct.calcsize('P') * 8)\""

  # Check NumPy installed correctly
  - cmd: pip list

  - cd %REPO_DIR%
  - mkdir %REPO_DIR%\build\
  - mkdir %REPO_DIR%\build\release
  - mkdir %REPO_DIR%\build\scripts

  # Remove sh.exe from the paths (CMake doesn't like it)
  - set PATH=%PATH:C:\Program Files (x86)\Git\bin;=%
  - set PATH=%PATH:C:\Program Files\Git\usr\bin;=%
  - set PATH=%PATH:C:\MinGW\msys\1.0\bin;=%

  # Fake KJ-Async and Capnp-RPC libs, not needed in Lite mode
  # http://www.cmake.org/Wiki/CmakeMingw
  - cd %REPO_DIR%\build\scripts
  - cmake -G "MinGW Makefiles" 
      -DCMAKE_BUILD_TYPE=Debug 
      -DCMAKE_INSTALL_PREFIX=%REPO_DIR%\build\release 
      -DPYTHON_LIBRARY=%PYTHONPATH%\libs\libpython27.dll.a 
      -DPYTHON_INCLUDE_DIR=%PYTHONPATH%\include 
      -DCAPNP_INCLUDE_DIRS=%REPO_DIR%\external\windows64\include 
      -DCAPNP_EXECUTABLE=%REPO_DIR%\external\windows64\bin\capnp.exe 
      -DCAPNPC_CXX_EXECUTABLE=%REPO_DIR%\external\windows64\bin\capnpc-c++.exe 
      -DLIB_KJ=%EXT_LIBS%\libkj.a 
      -DLIB_CAPNP=%EXT_LIBS%\libcapnp.a 
      -DLIB_CAPNPC=%EXT_LIBS%\libcapnp.a 
      -DCAPNP_LIB_KJ=%EXT_LIBS%\libkj.a 
      -DCAPNP_LIB_CAPNP=%EXT_LIBS%\libcapnp.a 
      -DCAPNP_LIB_KJ-ASYNC=%EXT_LIBS%\libkj.a 
      -DCAPNP_LIB_CAPNP-RPC=%EXT_LIBS%\libcapnp.a 
      -DLIB_STATIC_APR1_LOC=%EXT_LIBS%\libapr-1.a 
      -DLIB_STATIC_APRUTIL1_LOC=%EXT_LIBS%\libaprutil-1.a 
      -DLIB_STATIC_YAML_CPP_LOC=%EXT_LIBS%\libyaml-cpp.a 
      -DLIB_STATIC_YAML_LOC=%EXT_LIBS%\libyaml.a 
      -DLIB_STATIC_Z_LOC=%EXT_LIBS%\libz.a 
      %REPO_DIR%

build_script:
  - cd %REPO_DIR%\build\scripts

  - mingw32-make -f Makefile -j3 --debug=v
  - mingw32-make -f Makefile install | findstr /C:"Install" /I /V

  - cd %REPO_DIR%

  - python setup.py bdist_wheel --debug --compiler=mingw --nupic-core-dir=%NUPIC_CORE_DIR%
  - ps: move .\bindings\py\dist\nupic.bindings-$env:BINDINGS_VERSION-cp27-none-win_amd64.whl .

after_build:
  - mkdir %ARTIFACTS_DIR%

  # legacy binary tests
  - cd %REPO_DIR%\build\release\bin
  - cpp_region_test.exe
  - unit_tests.exe --gtest_output=xml:%ARTIFACTS_DIR%\unit_tests_report.xml"

  - ps: >-
      if ($env:APPVEYOR_REPO_COMMIT -eq "master") {
{'fraction_non_alphanumeric': 0.1741833704528582, 'fraction_numerical': 0.028210838901262063, 'mean_word_length': 2.889209671598701, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 9, 'https://': 6, 'lorem ipsum': 0, 'www.': 6, 'xml': 4}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 10, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3980753', 'n_tokens_mistral': 4684, 'n_tokens_neox': 4257, 'n_words': 664}