forked from SuperTux/supertux
-
Notifications
You must be signed in to change notification settings - Fork 0
/
appveyor64.yml
87 lines (74 loc) · 2.37 KB
/
appveyor64.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
version: '{build}'
os: Visual Studio 2015
configuration: Release
platform: x64
environment:
DOWNLOAD_APIKEY:
secure: SEKmgfhiwujukYrr2xjqp63FEwvDUcoQOy7pCuYSyu+CTbGRRIzTbUCwwu4EPJmE
branches:
except:
- coverity_scan # No need for Windows builds on that branch
install:
- ps: |
Invoke-WebRequest https://download.supertux.org/builddep/dependencies-win64.zip -OutFile "$env:APPVEYOR_BUILD_FOLDER/dependencies.zip"
Add-Type -assembly "system.io.compression.filesystem"
[io.compression.zipfile]::ExtractToDirectory("$env:APPVEYOR_BUILD_FOLDER/dependencies.zip", "$env:APPVEYOR_BUILD_FOLDER/")
before_build:
- cmd: |
git submodule update --init --recursive
echo Running cmake ..
cmake -G "Visual Studio 14 2015 Win64" -DCMAKE_INSTALL_PREFIX=%P% -DHAVE_SDL=true -DPACKAGE_VCREDIST=true
build:
project: ALL_BUILD.vcxproj
parallel: true
verbosity: minimal
after_build:
- cmd: '"C:\Program Files (x86)\CMake\bin\cpack.exe"'
- ps: |
Write-Output Get-FileHash SuperTux-*
function transfer ($filename)
{
$file = Get-Item $filename;
invoke-webrequest -method put -infile $file.FullName https://transfer.sh/$($file.Name)
}
if(-not $Env:APPVEYOR_PULL_REQUEST_NUMBER) {
foreach ($path in get-ChildItem SuperTux-*) {
$response = transfer($path)
$url = $response.Content
$file = Get-Item $path;
$shasum = Get-FileHash $file -Algorithm SHA256
$postParams = @{
apikey=$Env:DOWNLOAD_APIKEY;
size=$file.length;
url=$url;
branch=$Env:APPVEYOR_REPO_BRANCH;
shasum = $shasum.Hash
}
Invoke-WebRequest -Uri https://download.supertux.org/submit.php -Method POST -Body $postParams
}
}
test: off
artifacts:
- path: SuperTux-*
name: setup
deploy:
- provider: GitHub
description: 'SuperTux release'
auth_token:
secure: 1sgroG7ycKHC6R2y/V7DECd/SHxXK4CNSDU7zZOnAlyBiVKT9ykvRKWt2DGcEZDq
artifact: setup
draft: true
on:
branch: master # release from master branch only
appveyor_repo_tag: true # deploy on tag push only
#- provider: BinTray
# username: maths22
# api_key:
# secure: 9miH0V65c10cbWfovqIfIHWsbyrg6jZDnaYxyGYHF5pyQbPnS+LcIX6Y/8gK2pM4
# subject: supertux
# repo: SuperTux-Nightly
# package: win64
# publish: true
# override: true
# on:
# branch: master