Skip to content
This repository has been archived by the owner on Jul 2, 2022. It is now read-only.

Commit

Permalink
chore: Add goreleaser
Browse files Browse the repository at this point in the history
  • Loading branch information
Jonnobrow committed Jan 24, 2022
1 parent 5c16b50 commit 13768a5
Show file tree
Hide file tree
Showing 4 changed files with 50 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,5 @@

# Dependency directories (remove the comment below to include it)
# vendor/

dist/
31 changes: 31 additions & 0 deletions .goreleaser.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# This is an example .goreleaser.yml file with some sensible defaults.
# Make sure to check the documentation at https://goreleaser.com
before:
hooks:
- go mod tidy
- go test ./...
builds:
- main: ./cmd/dev-toys
env:
- CGO_ENABLED=0
goos:
- linux
- windows
- darwin
archives:
- replacements:
darwin: Darwin
linux: Linux
windows: Windows
386: i386
amd64: x86_64
checksum:
name_template: "checksums.txt"
snapshot:
name_template: "{{ .Tag }}-next"
changelog:
sort: asc
filters:
exclude:
- "^docs:"
- "^test:"
14 changes: 14 additions & 0 deletions cmd/dev-toys/main.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
package main

import "fmt"

var (
version = "dev"
commit = "none"
date = "unknown"
builtBy = "unknown"
)

func main() {
fmt.Printf("dev-toys-cli %s, commit %s, built at %s by %s", version, commit, date, builtBy)
}
3 changes: 3 additions & 0 deletions go.mod
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
module github.com/jonnobrow/dev-toys-cli

go 1.17

0 comments on commit 13768a5

Please sign in to comment.