-
Notifications
You must be signed in to change notification settings - Fork 0
/
appveyor.yml
163 lines (136 loc) · 5.12 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
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
#
# Reference list
# - https://raw.githubusercontent.com/malaterre/GDCM/master/appveyor.yml
# - https://github.com/KhronosGroup/SPIRV-Tools/blob/master/.appveyor.yml
# - https://gitlab.com/eyeo/adblockplus/libadblockplus/blob/master/appveyor.yml
#
# http://www.appveyor.com/docs/build-cache#caching-chocolatey-packages
# https://github.com/kvirc/KVIrc/blob/master/.appveyor.yml
cache:
- C:\Tools\vcpkg\installed
# - 'C:\Program Files (x86)\NSIS'
# - C:\ProgramData\chocolatey\bin -> appveyor.yml
# - C:\ProgramData\chocolatey\lib -> appveyor.yml
# Set build version format here instead of in the admin panel.
version: '{build}'
environment:
matrix:
- APPVEYOR_BUILD_WORKER_IMAGE: Previous Visual Studio 2019
ROOT: c:\dev\source
SCRIPTS: '%ROOT%\scripts\'
CONFIG_PARTIAL: 'Release'
OS_PARTIAL: 'windows'
PLAT_PARTIAL: 'x86_64'
PRODUCT_NAME: Ember
RELEASE_VERSION: 0.0
TRIPLET: 'x64-windows-static'
OUTPUT_FOLDER: 'bin\$(CONFIG_PARTIAL)-$(OS_PARTIAL)-$(PLAT_PARTIAL)'
FILE_VERSION: 'v%RELEASE_VERSION%.$(appveyor_build_version)-beta'
GITHUB_TOKEN:
secure: ShOkS4UEj4aiSabXwn0u0d0d3BoaVF0wW7TO4JyFdmMfdckHk5IbF1rAJO3aaSRg
# Environment variables used by boost tests
BOOST_TEST_LOG_LEVEL: unit_scope
BOOST_TEST_REPORT_FORMAT: XML
BOOST_TEST_REPORT_LEVEL: short
BOOST_TEST_REPORT_SINK: test_report.xml
# stop infinite cycle of tag creation and build on tag
skip_tags: true
clone_depth: 1
# branches to build
branches:
# whitelist
only:
- develop
#---------------------------------#
# scripts that are called at #
# very beginning, before #
# repo cloning #
#---------------------------------#
init:
- cmd:
# Updating build version with correct values
# [has to be done here as environment variable are evaluated later in the process]
- appveyor UpdateBuild -Version "%RELEASE_VERSION%.%APPVEYOR_BUILD_NUMBER%"
# Print environment info ( set / systeminfo)
# - set PATH=%JAVA_HOME%\bin;%PYTHONHOME%;%PATH%
- msbuild /version
# https://github.com/chocolatey/chocolatey/issues/431
# - del c:\programdata\chocolatey\bin\cpack.exe
# separating output
- echo The current directory is %CD%
clone_folder: $(ROOT)
configuration:
- Release
#---------------------------------#
# scripts that install/setup #
#---------------------------------#
install:
# Recursively remove all outadet vcpkg packages
- cmd: vcpkg remove --outdated --recurse
# Install boost package
- cmd: 'vcpkg install boost-test:%TRIPLET%'
# show content of test dir to see if report is created.
- cmd: 'dir c:\tools\vcpkg\installed\%TRIPLET%\include'
# Update all submodules
- cmd: git submodule update --init
#---------------------------------#
# scripts to run before build #
#---------------------------------#
before_build:
# Generate VS2019 solution
- cmd: '%SCRIPTS%\generate_solution_vs2019.bat -s'
#---------------------------------#
# build step #
#---------------------------------#
build:
parallel: true # enable MSBuild parallel builds
project: pyro.sln # path to Visual Studio solution or project
#---------------------------------#
# scripts to run after build #
#---------------------------------#
after_build:
# Run test manually [until appveyor ]
- cmd: '%ROOT%/bin/%CONFIG_PARTIAL%-%OS_PARTIAL%-%PLAT_PARTIAL%/tests/tests.exe'
# show content of test dir to see if report is created.
- cmd: 'dir bin\%CONFIG_PARTIAL%-%OS_PARTIAL%-%PLAT_PARTIAL%\tests'
# Change directory, call installer script and step back one directory
# Operators in CMD https://stackoverflow.com/questions/28889954/what-does-do-in-this-batch-file/28889980#28889980
- cmd: "cd %SCRIPTS% & create_installer.bat %CONFIG_PARTIAL% -s"
# Renaming installer to include version in its name
- cmd: 'ren %OUTPUT_FOLDER%\installers\%PRODUCT_NAME%Setup.exe "%PRODUCT_NAME%-%FILE_VERSION%-setup.exe"'
test_script:
- cmd: vstest.console /logger:Appveyor %OUTPUT_FOLDER%\tests\tests.exe
#---------------------------------#
# artifacts configuration #
#---------------------------------#
artifacts:
- path: '**\*Setup.exe'
name: installer
- path: 'bin\**\ember\**.exe'
name: editor
- path: 'ember\assets\shaders\**'
name: editor
- path: 'ember\assets\textures\**'
name: editor
#---------------------------------#
# deployment configuration #
#---------------------------------#
# scripts to run before deployment
#before_deploy:
# scripts to run after deployment
#after_deploy:
# to run your custom scripts instead of provider deployments
#deploy_script:
deploy:
- provider: GitHub
auth_token:
secure: ShOkS4UEj4aiSabXwn0u0d0d3BoaVF0wW7TO4JyFdmMfdckHk5IbF1rAJO3aaSRg
release: "%PRODUCT_NAME%-%FILE_VERSION%"
description: 'Beta release of Ember editor v$(appveyor_build_version)'
# github automatically does source zip\tarball for us
artifact: installer
draft: false
prerelease: true
on:
branch: develop # release from master branch only
configuration: Release