forked from checkstyle/checkstyle
-
Notifications
You must be signed in to change notification settings - Fork 0
/
appveyor.yml
71 lines (66 loc) · 2.33 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
image: Visual Studio 2019
version: '{build}'
skip_tags: true
clone_depth: 10
branches:
only:
- master
except:
- gh-pages
install:
- ps: |
Add-Type -AssemblyName System.IO.Compression.FileSystem
if (!(Test-Path -Path "C:\maven\apache-maven-3.8.4" )) {
(new-object System.Net.WebClient).DownloadFile(
'https://downloads.apache.org/maven/maven-3/3.8.4/binaries/apache-maven-3.8.4-bin.zip',
'C:\maven-bin.zip'
)
[System.IO.Compression.ZipFile]::ExtractToDirectory("C:\maven-bin.zip", "C:\maven")
}
- cmd: SET M2_HOME=C:\maven\apache-maven-3.8.4
- cmd: SET PATH=%M2_HOME%\bin;%JAVA_HOME%\bin;%PATH%
- cmd: git config core.autocrlf
- cmd: mvn --version
- cmd: java -version
cache:
- C:\maven\apache-maven-3.8.4
- C:\Users\appveyor\.m2
matrix:
fast_finish: true
environment:
global:
CMD: " "
# https://stackoverflow.com/questions/42024619/maven-build-gets-connection-reset-when-downloading-artifacts
MAVEN_OPTS: "-Dhttp.keepAlive=false -Dmaven.wagon.http.retryHandler.count=3"
# We do matrix as AppVeyor could fail to finish simple "mvn -e verify"
# if he loose maven cache (happens from time to time)
matrix:
# checkstyle and sevntu.checkstyle (JDK11)
- JAVA_HOME: C:\Program Files\Java\jdk11
DESC: "checkstyle and sevntu.checkstyle (JDK11)"
CMD: "./.ci/validation.cmd sevntu"
# verify without checkstyle (JDK11)
- JAVA_HOME: C:\Program Files\Java\jdk11
DESC: "verify without checkstyle (JDK11)"
CMD: "./.ci/validation.cmd verify_without_checkstyle"
# site, without verify (JDK11)
- JAVA_HOME: C:\Program Files\Java\jdk11
DESC: "site, without verify (JDK11)"
CMD: "./.ci/validation.cmd site_without_verify"
build_script:
- ps: |
$RUN_JOB=1
if ($RUN_JOB -eq 1) {
$Expr = (get-content env:CMD)
Write-Host "CMD: $Expr"
Invoke-Expression $Expr
Write-Host "CMD exited with exit code $LastExitCode"
if ($LastExitCode -ne 0) {
exit $LastExitCode
}
} else {
Write-Host "build is skipped ..."
}
- ps: echo "Size of caches (bytes):"
- ps: Get-ChildItem -Recurse 'C:\maven\apache-maven-3.8.4' | Measure-Object -Property Length -Sum
- ps: Get-ChildItem -Recurse 'C:\Users\appveyor\.m2' | Measure-Object -Property Length -Sum