File tree Expand file tree Collapse file tree 2 files changed +16
-7
lines changed Expand file tree Collapse file tree 2 files changed +16
-7
lines changed Original file line number Diff line number Diff line change @@ -13,12 +13,15 @@ builds:
13
13
- darwin
14
14
ldflags : " -s -w"
15
15
archives :
16
- - replacements :
17
- darwin : Darwin
18
- linux : Linux
19
- windows : Windows
20
- 386 : i386
21
- amd64 : x86_64
16
+ - id : foo
17
+ name_template : >-
18
+ {{- .ProjectName }}_
19
+ {{- .Version }}_
20
+ {{- title .Os }}_
21
+ {{- if eq .Arch "amd64" }}x86_64
22
+ {{- else if eq .Arch "386" }}i386
23
+ {{- else }}{{ .Arch }}{{ end }}
24
+ {{- if .Arm }}v{{ .Arm }}{{ end -}}
22
25
checksum :
23
26
name_template : ' checksums.txt'
24
27
snapshot :
Original file line number Diff line number Diff line change @@ -50,7 +50,13 @@ function determineVersion() {
50
50
return process . env . INPUT_VERSION
51
51
}
52
52
const result = cp . execSync ( `curl --silent --location "https://api.github.com/repos/RoryQ/checkmate/releases/latest" | jq -r ".. .tag_name? // empty"` )
53
- return result . toString ( ) . trim ( ) ;
53
+ let ver = result . toString ( ) . trim ( ) ;
54
+ // fallback to v1.0.0
55
+ if ( ver === "" ) {
56
+ logDebug ( "No version found, falling back to v1.0.0" )
57
+ ver = "v1.0.0"
58
+ }
59
+ return ver
54
60
}
55
61
56
62
function main ( ) {
You can’t perform that action at this time.
0 commit comments