Skip to content

Commit 1d876f4

Browse files
committed
Update appveyor.yml
1 parent 55efd34 commit 1d876f4

File tree

1 file changed

+33
-12
lines changed

1 file changed

+33
-12
lines changed

appveyor.yml renamed to .appveyor.yml

Lines changed: 33 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -12,17 +12,29 @@ version: '{branch}-{build}'
1212
# Build worker image (VM template)
1313
image: Visual Studio 2017
1414

15+
# build platform, i.e. x86, x64, Any CPU. This setting is optional.
16+
platform: x64
17+
18+
# clone directory
19+
clone_folder: c:\projects\render_pipeline_cpp
20+
1521
# scripts that are called at very beginning, before repo cloning
1622
init:
17-
- cmd: >-
18-
git --version
23+
- ps: >-
24+
if (Test-Path env:TRIGGER_NAME) {
25+
Update-AppveyorBuild -Message "Build from $env:TRIGGER_COMMIT in $env:TRIGGER_NAME"
26+
}
1927
20-
cmake --version
28+
else {
29+
Set-AppveyorBuildVariable -Name 'TRIGGER_NAME' -Value "$env:APPVEYOR_PROJECT_NAME"
30+
Set-AppveyorBuildVariable -Name 'TRIGGER_COMMIT' -Value "$env:APPVEYOR_REPO_COMMIT".substring(0, 8)
31+
}
32+
33+
git --version
2134
2235
python --version
2336
24-
# clone directory
25-
clone_folder: c:\projects\render_pipeline_cpp
37+
cmake --version
2638
2739
# environment variables
2840
environment:
@@ -31,24 +43,21 @@ environment:
3143
FREETYPE_DIR: C:\projects\_install\panda3d-thirdparty\win-libs-vc14-x64\freetype
3244
PATH: C:\Python36-x64;%PATH%
3345

34-
# build cache to preserve files/folders between builds
35-
cache:
36-
- C:\projects\_cache
37-
3846
# scripts that run after cloning repository
3947
install:
4048
- cmd: >-
4149
git clone --depth 1 "https://github.com/bluekyu/render_pipeline_cpp_ci.git" c:\projects\render_pipeline_cpp_ci
4250
4351
mklink /J c:\projects\render_pipeline_cpp_ci\render_pipeline_cpp C:\projects\render_pipeline_cpp
4452
53+
# build cache to preserve files/folders between builds
54+
cache:
55+
- C:\projects\_cache
56+
4557
#---------------------------------#
4658
# build configuration #
4759
#---------------------------------#
4860

49-
# build platform, i.e. x86, x64, Any CPU. This setting is optional.
50-
platform: x64
51-
5261
# to run your custom scripts instead of automatic MSBuild
5362
build_script:
5463
- cmd: >-
@@ -63,3 +72,15 @@ build_script:
6372
artifacts:
6473
- path: _artifacts
6574
name: render_pipeline_cpp
75+
76+
#---------------------------------#
77+
# global handlers #
78+
#---------------------------------#
79+
80+
# on successful build
81+
on_success:
82+
- ps: >-
83+
Start-AppveyorBuild -ApiKey $env:api_key -ProjectSlug 'rpcpp_plugins' -EnvironmentVariables @{
84+
TRIGGER_NAME = $env:TRIGGER_NAME
85+
TRIGGER_COMMIT = $env:TRIGGER_COMMIT
86+
}

0 commit comments

Comments
 (0)