forked from go/golangs_learn
viviman
3 years ago
5 changed files with 42 additions and 21 deletions
@ -0,0 +1,2 @@ |
|||
|
|||
dist/ |
@ -0,0 +1,40 @@ |
|||
# This is an example .goreleaser.yml file with some sensible defaults. |
|||
# Make sure to check the documentation at https://goreleaser.com |
|||
# run : goreleaser --snapshot --skip-publish --rm-dist |
|||
before: |
|||
hooks: |
|||
# You may remove this if you don't use go modules. |
|||
- go mod tidy |
|||
# you may remove this if you don't need go generate |
|||
# - go generate ./... |
|||
builds: |
|||
- env: |
|||
- CGO_ENABLED=0 |
|||
id: "hyTool" |
|||
binary: "hyTool" |
|||
ldflags: -s -w -H=windowsgui |
|||
goos: |
|||
- linux |
|||
# - windows |
|||
goarch: |
|||
# - "386" |
|||
- amd64 |
|||
- arm |
|||
# - arm64 |
|||
archives: |
|||
- replacements: |
|||
darwin: Darwin |
|||
linux: Linux |
|||
windows: Windows |
|||
386: i386 |
|||
amd64: x86_64 |
|||
checksum: |
|||
name_template: 'checksums.txt' |
|||
snapshot: |
|||
name_template: "v1.0.0-hyTool" |
|||
changelog: |
|||
sort: asc |
|||
filters: |
|||
exclude: |
|||
- '^docs:' |
|||
- '^test:' |
@ -1,6 +0,0 @@ |
|||
SET CC=gcc |
|||
set GO111MODULE=on |
|||
SET CGO_ENABLED=0 |
|||
set GOARCH=amd64 |
|||
set GOOS=linux |
|||
go build main.go |
@ -1,6 +0,0 @@ |
|||
SET CC=gcc |
|||
set GO111MODULE=on |
|||
SET CGO_ENABLED=0 |
|||
set GOARCH=arm |
|||
set GOOS=linux |
|||
go build main.go |
@ -1,9 +0,0 @@ |
|||
SET CC=gcc |
|||
SET CGO_ENABLED=1 |
|||
# shellcheck disable=SC2121 |
|||
set GOARCH=amd64 |
|||
# shellcheck disable=SC2121 |
|||
set GOOS=darwin |
|||
rsrc -manifest main.manifest -ico main.ico -o main.syso |
|||
go generate |
|||
go build -gccgoflags="-DDARWIN -x objective-c -fobjc-arc" -ldflags="framework=Cocoa" . |
Loading…
Reference in new issue