Skip to content

Commit

Permalink
Goreleaser and Travis setup (#4)
Browse files Browse the repository at this point in the history
* Add minimal goreleaser + travis setup

* Remove commit variable injection

Co-authored-by: Bjørn <bjoern.soerensen@gmail.com>
  • Loading branch information
emilingerslev and Crevil authored Feb 3, 2020
1 parent c725fab commit 0b330dc
Show file tree
Hide file tree
Showing 2 changed files with 50 additions and 0 deletions.
30 changes: 30 additions & 0 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
builds:
- env:
- CGO_ENABLED=0
ldflags:
- "-s -w -X github.com/lunarway/strong-duckling/cmd.version={{.Version}}"

archive:
format: binary
name_template: "{{ .ProjectName }}-{{ .Os }}-{{ .Arch }}"
replacements:
darwin: darwin
linux: linux
windows: windows
386: i386

checksum:
name_template: "{{ .ProjectName }}-checksums.txt"

snapshot:
name_template: "git-{{.Commit}}"

release:
name_template: "v{{.Version}}"

changelog:
sort: asc
filters:
exclude:
- "^docs:"
- "^test:"
20 changes: 20 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
language: go

go:
- "1.13.x"

script: |
echo "Build strong-duckling" &&
go build &&
go test
services:
- docker

deploy:
- provider: script
skip_cleanup: true
script: curl -sL https://git.io/goreleaser | bash
on:
tags: true
condition: $TRAVIS_OS_NAME = linux

0 comments on commit 0b330dc

Please sign in to comment.