-
Notifications
You must be signed in to change notification settings - Fork 8
/
appveyor.yml
83 lines (73 loc) · 2.66 KB
/
appveyor.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
# Heavily inspired from https://github.com/CheetahTemplate3/cheetah3
version: '{branch}-{build}'
cache:
- '%LOCALAPPDATA%\pip\Cache'
# Match travis
clone_depth: 50
skip_branch_with_pr: true
environment:
global:
# SDK v7.0 MSVC Express 2008's SetEnv.cmd script will fail if the
# /E:ON and /V:ON options are not enabled in the batch script intepreter
# See: http://stackoverflow.com/a/13751649/163740
CMD_IN_ENV: "cmd /E:ON /V:ON /C CI\\run_with_env.cmd"
matrix:
- PYTHON_VERSION: "3.8"
PYTHON_ARCH: "32"
PYTHON_HOME: "C:\\Python38"
- PYTHON_VERSION: "3.8"
PYTHON_ARCH: "64"
PYTHON_HOME: "C:\\Python38-x64"
- PYTHON_VERSION: "3.9"
PYTHON_ARCH: "32"
PYTHON_HOME: "C:\\Python39"
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
- PYTHON_VERSION: "3.9"
PYTHON_ARCH: "64"
PYTHON_HOME: "C:\\Python39-x64"
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
- PYTHON_VERSION: "3.10"
PYTHON_ARCH: "32"
PYTHON_HOME: "C:\\Python310"
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
- PYTHON_VERSION: "3.10"
PYTHON_ARCH: "64"
PYTHON_HOME: "C:\\Python310-x64"
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
- PYTHON_VERSION: "3.11"
PYTHON_ARCH: "32"
PYTHON_HOME: "C:\\Python311"
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2022
- PYTHON_VERSION: "3.11"
PYTHON_ARCH: "64"
PYTHON_HOME: "C:\\Python311-x64"
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2022
- PYTHON_VERSION: "3.12"
PYTHON_ARCH: "32"
PYTHON_HOME: "C:\\Python312"
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2022
- PYTHON_VERSION: "3.12"
PYTHON_ARCH: "64"
PYTHON_HOME: "C:\\Python312-x64"
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2022
install:
# Ensure we use the right python version
- "SET PATH=%PYTHON_HOME%;%PYTHON_HOME%\\Scripts;%PATH%"
- "SET TOXPYTHON=%PYTHON_HOME%\\python.exe"
- "python --version"
- "python -c \"import struct; print(struct.calcsize('P') * 8)\""
- "python -m pip install --upgrade pip cython pytest tox ppu setuptools"
- "pip --version"
build_script:
- "%WITH_ENV% python setup.py build_ext --inplace"
test_script:
- "%CMD_IN_ENV% pytest"
deploy_script:
# If tests are successful and we've tested a tag, deploy binary wheel
# TWINE_USERNAME / TWINE_PASSWORD / TWINE_REPOSITORY_URL
# must be set in AppVeyor settings.
- if "%APPVEYOR_REPO_TAG%" == "true" (
pip install --upgrade twine "wheel==0.42.0" &&
%CMD_IN_ENV% python setup.py bdist_wheel &&
twine upload --skip-existing dist\\*.whl --repository-url %TWINE_REPOSITORY_URL% -u %TWINE_USERNAME% -p %TWINE_PASSWORD%
)