Skip to content

Commit

Permalink
Add deploy config using goreleaser
Browse files Browse the repository at this point in the history
  • Loading branch information
arunvelsriram committed Sep 5, 2020
1 parent de0f367 commit bc286e1
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 1 deletion.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
.idea
bin
out
coverage
17 changes: 17 additions & 0 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
builds:
- goos:
- linux
goarch:
- amd64
archive:
replacements:
linux: Linux
amd64: x86_64
checksum:
name_template: "checksums.txt"
snapshot:
name_template: "{{ .Tag }}-next"
changelog:
sort: asc
release:
draft: true
7 changes: 7 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,10 @@ env:
global:
- GO111MODULE=on
script: make check
deploy:
- provider: script
skip_cleanup: false
script: curl -sL https://git.io/goreleaser | bash
on:
tags: true
condition: "$TRAVIS_OS_NAME = linux"
3 changes: 2 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
.PHONY: help

APP=sftp-exporter
APP_EXECUTABLE="./out/$(APP)"
GOLANGCI_LINT_VERSION=v1.30.0
MOCKGEN_VERSION=v1.4.3

Expand All @@ -26,7 +27,7 @@ lint: install-golangci-lint ## run lint
$(GOLANGCI_LINT) run -v

build: ## compile the app
go build -o ./bin/$(APP) main.go
go build -o $(APP_EXECUTABLE) main.go

test: ## run unit tests
mkdir -p coverage
Expand Down

0 comments on commit bc286e1

Please sign in to comment.