File tree 4 files changed +22
-1
lines changed
4 files changed +22
-1
lines changed Original file line number Diff line number Diff line change 47
47
48
48
- name : Build the Agent
49
49
run : task build
50
+ if : matrix.operating-system != 'windows-latest'
51
+
52
+ - name : Build the Agent for win
53
+ run : task build-win
54
+ if : matrix.operating-system == 'windows-latest'
50
55
51
56
- name : Run unit tests
52
57
run : task test-unit
Original file line number Diff line number Diff line change 7
7
cmds :
8
8
- go build -v -i {{.LDFLAGS}}
9
9
10
+ build-win :
11
+ desc : Build the project for win
12
+ cmds :
13
+ - go get github.com/akavel/rsrc
14
+ - rsrc -arch=386 -manifest=manifest.xml
15
+ - go build -v -i {{.WIN_LDFLAGS}}
16
+ - rm rsrc.syso
17
+
10
18
test :
11
19
desc : Run the full testsuite, `legacy` will be skipped
12
20
cmds :
@@ -39,13 +47,18 @@ vars:
39
47
DEFAULT_TARGETS :
40
48
sh : echo `go list ./... | grep -v 'arduino-create-agent/gen/' | tr '\n' ' '`
41
49
# build vars
50
+ WIN_FLAGS : -H=windowsgui
42
51
COMMIT :
43
52
sh : echo ${TRAVIS_COMMIT:-`git log -n 1 --format=%h`}
44
53
TAG :
45
54
sh : echo `git describe --tags --abbrev=0`
46
55
LDFLAGS : >
47
56
-ldflags '-X main.version={{.TAG}}
48
57
-X main.git_revision={{.COMMIT}}'
58
+ WIN_LDFLAGS : >
59
+ -ldflags '-X main.version={{.TAG}}
60
+ -X main.git_revision={{.COMMIT}}
61
+ {{.WIN_FLAGS}}'
49
62
# test vars
50
63
GOFLAGS : " -timeout 10m -v -coverpkg=./... -covermode=atomic"
51
64
TEST_VERSIONSTRING : " 0.0.0-alpha"
61
74
# DOCS_VERSION: dev
62
75
# DOCS_ALIAS: ""
63
76
# DOCS_REMOTE: "origin"
64
-
77
+
Original file line number Diff line number Diff line change @@ -3,6 +3,7 @@ module github.com/arduino/arduino-create-agent
3
3
go 1.14
4
4
5
5
require (
6
+ github.com/akavel/rsrc v0.9.0 // indirect
6
7
github.com/blang/semver v3.5.1+incompatible
7
8
github.com/codeclysm/extract v2.0.0+incompatible
8
9
github.com/creack/goselect v0.0.0-20180501195510-58854f77ee8d
Original file line number Diff line number Diff line change
1
+ github.com/akavel/rsrc v0.9.0 h1:HwUDC0+tMFWqN4D5G+o5siGD4oVsC3jn6zM8ocjc3nY =
2
+ github.com/akavel/rsrc v0.9.0 /go.mod h1:uLoCtb9J+EyAqh+26kdrTgmzRBFPGOolLWKpdxkKq+c =
1
3
github.com/blang/semver v3.5.1+incompatible h1:cQNTCjp13qL8KC3Nbxr/y2Bqb63oX6wdnnjpJbkM4JQ =
2
4
github.com/blang/semver v3.5.1+incompatible /go.mod h1:kRBLl5iJ+tD4TcOOxsy/0fnwebNt5EWlYSAyrTnjyyk =
3
5
github.com/codeclysm/extract v2.0.0+incompatible h1:+b4WsD7YuZ5u3iW5T5TWbO764zUyEpQZSH5tZbjAxXQ =
You can’t perform that action at this time.
0 commit comments