This repository was archived by the owner on Feb 21, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #18 from dbarbuzzi/build-with-mage-goreleaser
Build with Mage & Goreleaser
- Loading branch information
Showing
7 changed files
with
118 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
project_name: tvd | ||
before: | ||
hooks: | ||
- bash .clientid | ||
release: | ||
github: | ||
owner: dbarbuzzi | ||
name: tvd | ||
draft: true | ||
archive: | ||
replacements: | ||
darwin: macOS | ||
linux: Linux | ||
windows: Windows | ||
386: 32bit | ||
amd64: 64bit | ||
format_overrides: | ||
- goos: windows | ||
format: zip | ||
checksum: | ||
name_template: '{{ .ProjectName }}_{{ .Version }}_checksums.txt' | ||
snapshot: | ||
name_template: "{{ .Tag }}-next" | ||
changelog: | ||
sort: asc | ||
filters: | ||
exclude: | ||
- '^docs:' | ||
- '^test:' | ||
build: | ||
binary: tvd | ||
ldflags: "-s -w -X main.Version={{ .Version }} -X main.ClientID=${TVD_CLIENT_ID}" | ||
goos: | ||
- darwin | ||
- linux | ||
- windows | ||
goarch: | ||
- amd64 | ||
- 386 | ||
env: | ||
- CGO_ENABLED=0 | ||
brew: | ||
name: tvd | ||
github: | ||
owner: dbarbuzzi | ||
name: hombrew-tap | ||
commit_author: | ||
name: dbarbuzzi | ||
email: [email protected] | ||
folder: Formula | ||
homepage: "https://github.com/dbarbuzzi/tvd" | ||
description: "Download Twitch VODs" | ||
test: | | ||
system "#{bin}/tvd --version" | ||
install: | | ||
bin.install "tvd" | ||
scoop: | ||
bucket: | ||
owner: dbarbuzzi | ||
name: scoop-bucket | ||
commit_author: | ||
name: dbarbuzzi | ||
email: [email protected] | ||
homepage: "https://github.com/dbarbuzzi/tvd" | ||
description: "Download Twitch VODs" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
github.com/BurntSushi/toml v0.3.0 h1:e1/Ivsx3Z0FVTV0NSOv/aVgbUWyQuzj7DDnFblkRvsY= | ||
github.com/BurntSushi/toml v0.3.0/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= | ||
github.com/mattn/go-runewidth v0.0.2 h1:UnlwIPBGaTZfPQ6T1IGzPI0EkYAQmT9fAEJ/poFC63o= | ||
github.com/mattn/go-runewidth v0.0.2/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU= | ||
golang.org/x/sys v0.0.0-20180715085529-ac767d655b30 h1:4bYUqrXBoiI7UFQeibUwFhvcHfaEeL75O3lOcZa964o= | ||
golang.org/x/sys v0.0.0-20180715085529-ac767d655b30/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= | ||
gopkg.in/cheggaaa/pb.v1 v1.0.25 h1:Ev7yu1/f6+d+b3pi5vPdRPc6nNtP1umSfcWiEfRqv6I= | ||
gopkg.in/cheggaaa/pb.v1 v1.0.25/go.mod h1:V/YB90LKu/1FcN3WVnfiiE5oMCibMjukxqG/qStrOgw= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
// +build mage | ||
|
||
package main | ||
|
||
import ( | ||
"os/exec" | ||
) | ||
|
||
func Build() error { | ||
cmd := exec.Command("goreleaser", "release", "--rm-dist", "--skip-publish") | ||
return cmd.Run() | ||
} | ||
|
||
func Release() error { | ||
cmd := exec.Command("goreleaser", "release", "--rm-dist") | ||
return cmd.Run() | ||
} | ||
|
||
func Snapshot() error { | ||
cmd := exec.Command("goreleaser", "release", "--rm-dist", "--snapshot") | ||
return cmd.Run() | ||
} |