-
Notifications
You must be signed in to change notification settings - Fork 48
/
.appveyor.yml
152 lines (137 loc) · 6.29 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
# AppVeyor build configuration
# https://www.appveyor.com/docs/build-configuration
# https://www.appveyor.com/docs/appveyor-yml/
# version format
version: 1.0.{build}
image: Visual Studio 2017
platform:
- x64
# Clone project into GOPATH folder
clone_folder: c:\gopath\src\github.com\skycoin\cx
# Define environment variables
environment:
GOPATH: c:\gopath
MINGW_W64: C:\msys64\mingw64\bin
MSYS_W64: C:\msys64\usr\bin
APPVEYOR_RDP_PASSWORD: J8kDX3vVHGBT
MSYSTEM: MINGW64
stack: go 1.11
# Do some things at start
init:
# Enable Windows RDP Client Access to Build Worker
- ps: iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
- set PATH=%MINGW_W64%;%MSYS_W64%;%GOPATH%\bin;%PATH%
# Install go dev dependencies
install:
- bash -lc "pacman --noconfirm -S bash pacman pacman-mirrors"
- bash -lc "pacman --noconfirm -S mingw-w64-x86_64-gcc mingw64/mingw-w64-x86_64-pkg-config mingw-w64-x86_64-gtk3 mingw-w64-x86_64-devhelp mingw-w64-x86_64-glade mingw-w64-x86_64-toolchain base-devel"
- bash -c "sed -i -e 's/-Wl,-luuid/-luuid/g' C:/msys64/mingw64/lib/pkgconfig/gdk-3.0.pc"
- go version
- go get github.com/skycoin/skycoin/...
- go get github.com/go-gl/gl/v2.1/gl
- go get github.com/go-gl/glfw/v3.2/glfw
- go get github.com/go-gl/gltext
- go get github.com/cznic/goyacc
# - go get -v ./...
# scripts to run before build
before_build:
- goyacc -o %GOPATH%\src\github.com\skycoin\cx\cxparser\cxpartialparsing\partialparsing.go %GOPATH%\src\github.com\skycoin\cx\cxparser\cxpartialparsing\partialparsing.y
- goyacc -o %GOPATH%\src\github.com\skycoin\cx\cxparser\cxparsingcompletor\parsingcompletor.go %GOPATH%\src\github.com\skycoin\cx\cxparser\cxparsingcompletor\parsingcompletor.y
# use custom build_script
build_script:
- go build -race -tags="base opengl" -i -o %GOPATH%\bin\cx.exe github.com\skycoin\cx\cxparser\
# Copy cx executable into project folder to avoid relative path problems
after_build:
- copy c:\gopath\bin\cx.exe c:\gopath\src\github.com\skycoin\cx\
# use custom test_script
test_script:
- go test -race -tags="base opengl" -i -o %GOPATH%\bin\cx github.com\skycoin\cx\cxparser\
- cmd: cx.exe %GOPATH%\src\github.com\skycoin\cx\lib\args.cx %GOPATH%\src\github.com\skycoin\cx\tests\main.cx ++cxpath=%GOPATH%\bin\cx.exe ++wdir=%GOPATH%\src\github.com\skycoin\cx\tests ++disable-tests=gui,issue
#specify artifacts to upload
artifacts:
- path: 'cx.exe'
name: cx-win64.exe
# on successful build
on_success:
- ECHO "BUILD VICTORY"
# on build failure
on_failure:
- ECHO "TRY AND TRY AGAIN"
# after build failure or success
on_finish:
- ps: $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
# https://www.appveyor.com/docs/environment-variables/
# Environment variables that are set by AppVeyor for every build:
# APPVEYOR - True if build runs in AppVeyor environment;
- ECHO %APPVEYOR%
# CI - True if build runs in AppVeyor environment;
- ECHO %CI%
# APPVEYOR_API_URL - AppVeyor Build Agent API URL;
- ECHO %APPVEYOR_API_URL%
# APPVEYOR_ACCOUNT_NAME - account name;
- ECHO %APPVEYOR_ACCOUNT_NAME%
# APPVEYOR_PROJECT_ID - AppVeyor unique project ID;
- ECHO %APPVEYOR_PROJECT_ID%
# APPVEYOR_PROJECT_NAME - project name;
- ECHO %APPVEYOR_PROJECT_NAME%
# APPVEYOR_PROJECT_SLUG - project slug (as seen in project details URL);
- ECHO %APPVEYOR_PROJECT_SLUG%
# APPVEYOR_BUILD_FOLDER - path to clone directory;
- ECHO %APPVEYOR_BUILD_FOLDER%
# APPVEYOR_BUILD_ID - AppVeyor unique build ID;
- ECHO %APPVEYOR_BUILD_ID%
# APPVEYOR_BUILD_NUMBER - build number;
- ECHO %APPVEYOR_BUILD_NUMBER%
# APPVEYOR_BUILD_VERSION - build version;
- ECHO %APPVEYOR_BUILD_VERSION%
# APPVEYOR_PULL_REQUEST_NUMBER - GitHub Pull Request number;
- ECHO %APPVEYOR_PULL_REQUEST_NUMBER%
# APPVEYOR_PULL_REQUEST_TITLE - GitHub Pull Request title
- ECHO %APPVEYOR_PULL_REQUEST_TITLE%
# APPVEYOR_JOB_ID - AppVeyor unique job ID;
- ECHO %APPVEYOR_JOB_ID%
# APPVEYOR_JOB_NAME - job name;
- ECHO %APPVEYOR_JOB_NAME%
# APPVEYOR_REPO_PROVIDER - github, bitbucket, kiln, vso or gitlab;
- ECHO %APPVEYOR_REPO_PROVIDER%
# APPVEYOR_REPO_SCM - git or mercurial;
- ECHO %APPVEYOR_REPO_SCM%
# APPVEYOR_REPO_NAME - repository name in format owner-name/repo-name;
- ECHO %APPVEYOR_REPO_NAME%
# APPVEYOR_REPO_BRANCH - build branch. For Pull Request commits it is base branch PR is merging into;
- ECHO %APPVEYOR_REPO_BRANCH%
# APPVEYOR_REPO_TAG - true if build has started by pushed tag; otherwise false;
- ECHO %APPVEYOR_REPO_TAG%
# APPVEYOR_REPO_TAG_NAME - contains tag name for builds started by tag; otherwise this variable is undefined;
- ECHO %APPVEYOR_REPO_TAG_NAME%
# APPVEYOR_REPO_COMMIT - commit ID (SHA);
- ECHO %APPVEYOR_REPO_COMMIT%
# APPVEYOR_REPO_COMMIT_AUTHOR - commit author’s name;
- ECHO %APPVEYOR_REPO_COMMIT_AUTHOR%
# APPVEYOR_REPO_COMMIT_AUTHOR_EMAIL - commit author’s email address;
- ECHO %APPVEYOR_REPO_COMMIT_AUTHOR_EMAIL%
# APPVEYOR_REPO_COMMIT_TIMESTAMP - commit date/time;
- ECHO %APPVEYOR_REPO_COMMIT_TIMESTAMP%
#
# commit message disabled; can cause false failure
#
# APPVEYOR_REPO_COMMIT_MESSAGE - commit message;
# - ECHO %APPVEYOR_REPO_COMMIT_MESSAGE%
# APPVEYOR_REPO_COMMIT_MESSAGE_EXTENDED - the rest of commit message after line break (if exists);
# - ECHO %APPVEYOR_REPO_COMMIT_MESSAGE_EXTENDED%
# APPVEYOR_SCHEDULED_BUILD - True if the build runs by scheduler;
- ECHO %APPVEYOR_SCHEDULED_BUILD%
# APPVEYOR_FORCED_BUILD (True or undefined) - builds started by “New build” button or from the same API;
- ECHO %APPVEYOR_FORCED_BUILD%
# APPVEYOR_RE_BUILD (True or undefined) - build started by “Re-build commit/PR” button of from the same API;
- ECHO %APPVEYOR_RE_BUILD%
# PLATFORM - platform name set on Build tab of project settings (or through platform parameter in appveyor.yml);
- ECHO %PLATFORM%
# CONFIGURATION - configuration name set on Build tab of project settings (or through configuration parameter in appveyor.yml);
- ECHO %CONFIGURATION%
#---------------------------------#
# notifications #
#---------------------------------#
notifications:
- provider: Webhook
url: https://fathomless-fjord-24024.herokuapp.com/notify