environment:

  global:
    SEABREEZE: "3.0.11.11"
    SEABREEZE_PATH: "C:\\SeaBreeze"

  matrix:

    # For Python versions available on Appveyor, see
    # http://www.appveyor.com/docs/installed-software#python

    - PYTHON: "C:\\Python27"
      PYTHON_ARCH: "32"
      VSC_V: "vc9"
      WDDK_LIB_PATH: "C:\\WinDDK\\7600.16385.1\\lib\\wxp\\i386"
    - PYTHON: "C:\\Python35"
      PYTHON_ARCH: "32"
      VSC_V: "vc14"
      WDDK_LIB_PATH: "C:\\WinDDK\\7600.16385.1\\lib\\wxp\\i386"
    - PYTHON: "C:\\Python36"
      PYTHON_ARCH: "32"
      VSC_V: "vc14"
      WDDK_LIB_PATH: "C:\\WinDDK\\7600.16385.1\\lib\\wxp\\i386"

    - PYTHON: "C:\\Python27-x64"
      PYTHON_ARCH: "64"
      VSC_V: "vc9"
      WDDK_LIB_PATH: "C:\\WinDDK\\7600.16385.1\\lib\\wlh\\amd64"
    - PYTHON: "C:\\Python35-x64"
      PYTHON_ARCH: "64"
      VSC_V: "vc14"
      WDDK_LIB_PATH: "C:\\WinDDK\\7600.16385.1\\lib\\wlh\\amd64"
    - PYTHON: "C:\\Python36-x64"
      PYTHON_ARCH: "64"
      VSC_V: "vc14"
      WDDK_LIB_PATH: "C:\\WinDDK\\7600.16385.1\\lib\\wlh\\amd64"

install:
  # Setup the build environment
  - "%PYTHON%\\python.exe -m pip install --disable-pip-version-check --user --upgrade pip"
  - "%PYTHON%\\python.exe -m pip install wheel"
  - "%PYTHON%\\python.exe -m pip install cython==0.25.2"

  # Install Seabreeze
  - "appveyor DownloadFile https://github.com/ap--/libseabreeze/releases/download/libseabreeze-%SEABREEZE%/libseabreeze-%SEABREEZE%-%PYTHON_ARCH%-%VSC_V%.zip -FileName sb.zip"
  - cmd: 7z x sb.zip -o%SEABREEZE_PATH% 

build: off

test_script:
  - "echo 'starting'"

after_test:
  # build_cmd form http://python-packaging-user-guide.readthedocs.org/en/latest/appveyor/
  - '.\\appveyor\\build.cmd %PYTHON%\\python.exe setup.py build_ext --library-dirs="%SEABREEZE_PATH%;%WDDK_LIB_PATH%"'
  - ".\\appveyor\\build.cmd %PYTHON%\\python.exe setup.py build"
  - ".\\appveyor\\build.cmd %PYTHON%\\python.exe setup.py bdist_wheel"

artifacts:
  - path: dist\*
    name: wheel

deploy:
  release: $(appveyor_repo_tag_name)
  provider: GitHub
  auth_token:
    secure: 2jmPAIr0bDr/Aak6PsCtd5nRPQpHEKwjKN13k4fDp4f6fbibuLmGEkQspQguQwFe
  artifact: wheel
  draft: false
  prerelease: false
  on:
    appveyor_repo_tag: true        # deploy on tag push only
