File tree Expand file tree Collapse file tree 5 files changed +20
-17
lines changed Expand file tree Collapse file tree 5 files changed +20
-17
lines changed Original file line number Diff line number Diff line change 1
1
name : release
2
2
3
3
on :
4
+ # Release on demand
4
5
workflow_dispatch :
5
6
releaseType :
6
7
description : " Release Type"
28
29
uses : actions/setup-go@v2
29
30
with :
30
31
go-version : 1.19
32
+ - name : Run tests
33
+ run : go test -v ./...
31
34
- name : Build with goreleaser
32
35
uses : goreleaser/goreleaser-action@v3
33
36
with :
Original file line number Diff line number Diff line change 3
3
hooks :
4
4
- go mod tidy
5
5
builds :
6
- - main : ./cmd/devbox.go
6
+ - main : ./cmd/devbox/main .go
7
7
binary : devbox
8
8
mod_timestamp : " {{ .CommitTimestamp }}" # For reproducible builds
9
9
ldflags :
@@ -21,7 +21,7 @@ archives:
21
21
snapshot :
22
22
name_template : ' {{ incpatch .Version }}-dev{{ time "20060102" }}'
23
23
checksum :
24
- name_template : " {{ .ProjectName }}_{{ .Version }}_checksums .txt"
24
+ name_template : " checksums .txt"
25
25
algorithm : sha256
26
26
release :
27
27
prerelease : auto
Original file line number Diff line number Diff line change 1
- load ("@io_bazel_rules_go//go:def.bzl" , "go_binary" , "go_library" )
2
-
3
- go_library (
4
- name = "cmd_lib" ,
5
- srcs = ["devbox.go" ],
6
- importpath = "go.jetpack.io/devbox/cmd" ,
7
- visibility = ["//visibility:private" ],
8
- deps = ["//opensource/devbox/boxcli" ],
9
- )
10
-
11
- go_binary (
12
- name = "cmd" ,
13
- embed = [":cmd_lib" ],
14
- visibility = ["//visibility:public" ],
15
- )
Original file line number Diff line number Diff line change
1
+ load ("@io_bazel_rules_go//go:def.bzl" , "go_binary" , "go_library" )
2
+
3
+ go_library (
4
+ name = "devbox_lib" ,
5
+ srcs = ["main.go" ],
6
+ importpath = "go.jetpack.io/devbox/cmd/devbox" ,
7
+ visibility = ["//visibility:private" ],
8
+ deps = ["//opensource/devbox/boxcli" ],
9
+ )
10
+
11
+ go_binary (
12
+ name = "devbox" ,
13
+ embed = [":devbox_lib" ],
14
+ visibility = ["//visibility:public" ],
15
+ )
File renamed without changes.
You can’t perform that action at this time.
0 commit comments