readlink on Windows/python3 requires a unicode string.
[jelmer/dulwich.git] / appveyor.yml
1 environment:
2
3   matrix:
4
5     - PYTHON: "C:\\Python27"
6       PYTHON_VERSION: "2.7.x"
7       PYTHON_ARCH: "32"
8
9     - PYTHON: "C:\\Python27-x64"
10       PYTHON_VERSION: "2.7.x"
11       PYTHON_ARCH: "64"
12
13     - PYTHON: "C:\\Python33"
14       PYTHON_VERSION: "3.3.x"
15       PYTHON_ARCH: "32"
16
17     - PYTHON: "C:\\Python33-x64"
18       PYTHON_VERSION: "3.3.x"
19       PYTHON_ARCH: "64"
20
21     - PYTHON: "C:\\Python34"
22       PYTHON_VERSION: "3.4.x"
23       PYTHON_ARCH: "32"
24
25     - PYTHON: "C:\\Python34-x64"
26       PYTHON_VERSION: "3.4.x"
27       PYTHON_ARCH: "64"
28
29     - PYTHON: "C:\\Python35"
30       PYTHON_VERSION: "3.5.x"
31       PYTHON_ARCH: "32"
32
33     - PYTHON: "C:\\Python35-x64"
34       PYTHON_VERSION: "3.5.x"
35       PYTHON_ARCH: "64"
36
37     - PYTHON: "C:\\Python36"
38       PYTHON_VERSION: "3.6.x"
39       PYTHON_ARCH: "32"
40
41     - PYTHON: "C:\\Python36-x64"
42       PYTHON_VERSION: "3.6.x"
43       PYTHON_ARCH: "64"
44
45 install:
46   # If there is a newer build queued for the same PR, cancel this one.
47   # The AppVeyor 'rollout builds' option is supposed to serve the same
48   # purpose but it is problematic because it tends to cancel builds pushed
49   # directly to master instead of just PR builds (or the converse).
50   # credits: JuliaLang developers.
51   - ps: if ($env:APPVEYOR_PULL_REQUEST_NUMBER -and $env:APPVEYOR_BUILD_NUMBER -ne ((Invoke-RestMethod `
52         https://ci.appveyor.com/api/projects/$env:APPVEYOR_ACCOUNT_NAME/$env:APPVEYOR_PROJECT_SLUG/history?recordsNumber=50).builds | `
53         Where-Object pullRequestId -eq $env:APPVEYOR_PULL_REQUEST_NUMBER)[0].buildNumber) { `
54           throw "There are newer queued builds for this pull request, failing early." }
55   - ECHO "Filesystem root:"
56   - ps: "ls \"C:/\""
57
58   - ECHO "Installed SDKs:"
59   - ps: "ls \"C:/Program Files/Microsoft SDKs/Windows\""
60
61   # Install Python (from the official .msi of http://python.org) and pip when
62   # not already installed.
63   - ps: if (-not(Test-Path($env:PYTHON))) { & appveyor\install.ps1 }
64
65   # Prepend newly installed Python to the PATH of this build (this cannot be
66   # done from inside the powershell script as it would require to restart
67   # the parent CMD process).
68   - "SET PATH=%PYTHON%;%PYTHON%\\Scripts;%PATH%"
69
70   # Check that we have the expected version and architecture for Python
71   - "python --version"
72   - "python -c \"import struct; print(struct.calcsize('P') * 8)\""
73
74   # Install setuptools/wheel so that we can e.g. use bdist_wheel
75   - "pip install setuptools wheel"
76
77   - "python setup.py develop"
78
79 build_script:
80   # Build the compiled extension
81   - "python setup.py build"
82
83 test_script:
84   - "python setup.py test"
85
86 after_test:
87   - "python setup.py bdist_wheel"
88   - "python setup.py bdist_wininst"
89   - "python setup.py bdist_msi"
90   - ps: "ls dist"
91
92 artifacts:
93   - path: dist\*