forked from CliMA/ClimateMachine.jl
-
Notifications
You must be signed in to change notification settings - Fork 0
/
azure-pipelines.yml
160 lines (140 loc) · 6 KB
/
azure-pipelines.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
trigger:
batch: true
branches:
include:
- master
- staging
- trying
jobs:
- job: Linux
timeoutInMinutes: 0
pool:
vmImage: 'ubuntu-16.04'
strategy:
matrix:
Julia 1.2:
JULIA_VERSION: '1.2'
steps:
- bash: |
set -o xtrace
wget -nv https://julialang-s3.julialang.org/bin/linux/x64/$(JULIA_VERSION)/julia-$(JULIA_VERSION)-latest-linux-x86_64.tar.gz
mkdir julia-$(JULIA_VERSION)
tar zxf julia-$(JULIA_VERSION)-latest-linux-x86_64.tar.gz -C julia-$(JULIA_VERSION) --strip-components 1
displayName: 'Download and extract Julia'
- bash: |
set -o xtrace
sudo apt-get update
sudo apt-get install mpich libmpich-dev
displayName: 'Install dependencies'
- bash: |
set -o xtrace
./julia-$(JULIA_VERSION)/bin/julia -e 'using InteractiveUtils; versioninfo()'
./julia-$(JULIA_VERSION)/bin/julia --project=@. -e 'using Pkg; Pkg.instantiate()'
./julia-$(JULIA_VERSION)/bin/julia --project=@. -e 'using Pkg; Pkg.test(coverage=true)'
displayName: 'Run the tests'
- bash: |
./julia-$(JULIA_VERSION)/bin/julia --project=.coverage -e 'using Pkg; Pkg.instantiate();
Pkg.add("Coverage");
using Coverage;
Codecov.submit_local(Codecov.process_folder();
service = "azure_pipelines",
commit = ENV["BUILD_SOURCEVERSION"],
pull_request = get(ENV, "SYSTEM_PULLREQUEST_PULLREQUESTNUMBER", "false"),
job = ENV["BUILD_DEFINITIONNAME"],
slug = ENV["BUILD_REPOSITORY_NAME"],
build = ENV["BUILD_BUILDID"])'
env:
CODECOV_TOKEN: "d5ad49b6-c247-44f7-a529-5f749a8b0c2a"
displayName: 'Submit code coverage'
continueOnError: true
- job: macOS
timeoutInMinutes: 0
pool:
vmImage: 'macOS-10.14'
strategy:
matrix:
Julia 1.2:
JULIA_VERSION: '1.2'
steps:
- bash: |
set -o xtrace
wget -nv https://julialang-s3.julialang.org/bin/mac/x64/$(JULIA_VERSION)/julia-$(JULIA_VERSION)-latest-mac64.dmg
mkdir juliamnt
hdiutil mount -readonly -mountpoint juliamnt julia-$(JULIA_VERSION)-latest-mac64.dmg
cp -a juliamnt/*.app/Contents/Resources/julia julia-$(JULIA_VERSION)
displayName: 'Download and extract Julia'
- bash: |
set -o xtrace
echo "127.0.0.1 $HOSTNAME" | sudo tee -a /private/etc/hosts # fix https://stackoverflow.com/a/31222970/392585
brew update
brew upgrade
brew install mpich
displayName: 'Install dependencies'
- bash: |
set -o xtrace
./julia-$(JULIA_VERSION)/bin/julia -e 'using InteractiveUtils; versioninfo()'
./julia-$(JULIA_VERSION)/bin/julia --project=@. -e 'using Pkg; Pkg.instantiate()'
./julia-$(JULIA_VERSION)/bin/julia --project=@. -e 'using Pkg; Pkg.test()'
displayName: 'Run the tests'
- job: Windows
timeoutInMinutes: 0
pool:
vmImage: 'VS2017-Win2016'
strategy:
matrix:
Julia 1.2:
JULIA_VERSION: '1.2'
steps:
- powershell: |
Set-PSDebug -Trace 1
wget https://julialang-s3.julialang.org/bin/winnt/x64/$(JULIA_VERSION)/julia-$(JULIA_VERSION)-latest-win64.exe -OutFile julia-$(JULIA_VERSION)-latest-win64.exe
Start-Process -FilePath .\julia-$(JULIA_VERSION)-latest-win64.exe -ArgumentList "/S /D=C:\julia-$(JULIA_VERSION)" -NoNewWindow -Wait
displayName: 'Download and extract Julia'
- powershell: |
Set-PSDebug -Trace 1
wget https://download.microsoft.com/download/2/E/C/2EC96D7F-687B-4613-80F6-E10F670A2D97/msmpisetup.exe -OutFile MSMpiSetup.exe
Start-Process -FilePath .\MSMpiSetup.exe "-unattend -minimal"
displayName: 'Install dependencies'
- powershell: |
Set-PSDebug -Trace 1
C:\julia-$(JULIA_VERSION)\bin\julia.exe -e 'using InteractiveUtils; versioninfo()'
C:\julia-$(JULIA_VERSION)\bin\julia.exe --project=@. -e 'using Pkg; Pkg.instantiate()'
C:\julia-$(JULIA_VERSION)\bin\julia.exe --project=@. -e 'using Pkg; Pkg.test()'
displayName: 'Run the tests'
- job: Documentation
pool:
vmImage: 'ubuntu-16.04'
strategy:
matrix:
Julia 1.2:
JULIA_VERSION: '1.2'
steps:
- bash: |
set -o xtrace
wget -nv https://julialang-s3.julialang.org/bin/linux/x64/$(JULIA_VERSION)/julia-$(JULIA_VERSION)-latest-linux-x86_64.tar.gz
mkdir julia-$(JULIA_VERSION)
tar zxf julia-$(JULIA_VERSION)-latest-linux-x86_64.tar.gz -C julia-$(JULIA_VERSION) --strip-components 1
displayName: 'Download and extract Julia'
- bash: |
set -o xtrace
sudo apt-get update
sudo apt-get install mpich libmpich-dev
displayName: 'Install dependencies'
- bash: |
set -o xtrace
export TRAVIS_REPO_SLUG="$BUILD_REPOSITORY_NAME"
export TRAVIS_PULL_REQUEST="${SYSTEM_PULLREQUEST_PULLREQUESTNUMBER:-false}"
if [[ $BUILD_SOURCEBRANCH == refs/tags/* ]]; then
export TRAVIS_TAG="${BUILD_SOURCEBRANCH:10}"
fi
if [[ $BUILD_SOURCEBRANCH == refs/heads/* ]]; then
export TRAVIS_BRANCH="${BUILD_SOURCEBRANCH:11}"
fi
./julia-$(JULIA_VERSION)/bin/julia -e 'using InteractiveUtils; versioninfo()'
./julia-$(JULIA_VERSION)/bin/julia --project=docs/ -e 'using Pkg; Pkg.instantiate();
Pkg.develop(PackageSpec(path=pwd()));
Pkg.build()'
./julia-$(JULIA_VERSION)/bin/julia --project=docs/ docs/make.jl
env:
DOCUMENTER_KEY: $(documenter_key)
displayName: 'Build and deploy docs'