-
Notifications
You must be signed in to change notification settings - Fork 6
/
appveyor.yml
67 lines (56 loc) · 1.76 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
version: '{build}'
build: off
clone_folder: C:\gopath\src\github.com\G-Node\gin-cli
stack: go 1.14
environment:
SRCDIR: C:\gopath\src\github.com\G-Node\gin-cli
GOPATH: C:\gopath
GO111MODULE: on
GOPROXY: https://proxy.golang.org
BINDIR: bin
# download dev build
BUNDLEREPO: https://gin.g-node.org/achilleas/gin-cli-builds/raw/master
matrix:
# 32-bit
- arch: "386"
bits: 32
# 64-bit
- arch: "amd64"
bits: 64
install:
- set PATH=C:\Python37-x64\;%PATH%;%GOPATH%\bin;c:\gin-bundle\git\usr\bin
# download latest stable gin-cli-windows-bundle
- md c:\gin-bundle
- cd c:\gin-bundle
- ps: Invoke-WebRequest -URI $env:BUNDLEREPO/gin-cli-latest-windows$env:bits.zip -OutFile "gin-cli-bundle.zip"
- 7z x gin-cli-bundle.zip
- git-annex version
# go stuff
- go version
- go env
build_script:
- cd %SRCDIR%
- go get -v ./...
- go vet ./...
- set GOARCH=%arch%
- go build -ldflags "-X main.gincliversion=APPVEYOR-%APPVEYOR_REPO_NAME%-%APPVEYOR_REPO_BRANCH% -X main.build=%APPVEYOR_BUILD_NUMBER% -X main.commit=%APPVEYOR_REPO_COMMIT%" -o %GOPATH%\bin\gin.exe .
before_test:
# python stuff
- python -m pip install pytest pyyaml
# clone tests submodule
- git submodule init
- git submodule update
# check that git and annex versions are detected properly
- gin --version
- gin help
test_script:
- go test -v ./...
- cd %SRCDIR%\tests
- python -m pytest -v -m "offline"
# to disable deployment
deploy: off
on_finish:
- appveyor PushArtifact %SRCDIR%\tests\log\gin.log
- appveyor PushArtifact %SRCDIR%\tests\log\runner.log
# Uncomment next line to enable RDP
# - ps: $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))