Skip to content

Commit

Permalink
Switch to gorelease
Browse files Browse the repository at this point in the history
  • Loading branch information
rs committed Mar 12, 2018
1 parent 246ccc7 commit 5f9ce33
Show file tree
Hide file tree
Showing 5 changed files with 45 additions and 69 deletions.
28 changes: 28 additions & 0 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
project_name: jaggr
builds:
-
env:
- CGO_ENABLED=0
goos:
- darwin
- linux
- freebsd
- windows
git:
short_hash: true
brew:
github:
owner: rs
name: homebrew-tap
commit_author:
name: Olivier Poitrey
email: rs@rhapsodyk.net
homepage: https://github.com/rs/jaggr
description: JSON Aggregation CLI
# snapcraft:
# summary: JSON Aggregation CLI
# grade: stable
# confinement: strict

release:
name_template: "{{.ProjectName}}-v{{.Version}}"
14 changes: 8 additions & 6 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,14 @@ matrix:
allow_failures:
- go: master
script: go test -v -race -cpu=1,2,4 -bench . -benchmem ./...
before_deploy: ./release
deploy:
provider: releases
file_glob: true
file: dist/*
- provider: script
skip_cleanup: true
script: curl -sL http://git.io/goreleaser | bash
on:
tags: true
api_key:
secure: IkUIPzZ9Nml4dGl6sQH1je0snBe2939+liuAB1IqUTNx+0mlMBC9cSHaHT+5BGL5G1QS31QcgW8jwcdspmHDZTPYkj9tw+GvGIs2nydjruqnhtRdoTeVzRRffZZVqdh1ktao4coZtNam5YlrgWvePhIm6kIYVMBcEgWff+a1/Uw9E3j+Aceo0LA/vrWdjUMNkN+qnKpF5TsNIMDXEwlukWEG1qdQgJZeNMcs/0WgZVrAx0wFsW3kQNdIynbMdY99K2VO90li3D+kSMQquYdcRBaU/ebpP+7mQ9OKTujxCuzU3IWoi05+EtmCDCp24ezL03fcF0UbITz6ORtHv67x36eTie+uXBWOPypiigNzGdtnRV6j2c1PmCxIoReiaLTbtUS9Unl8+87o9WXu0A/oCcN94fN4J19W19LR4npUai+OrrSYJYA8KaORcX//C5jZKcFYK0dFny/nd2sGhCyK81jJsR5Fmp5ePfZ4lhzDS4DrwD+BBO3ulvhmBysX+0tjg5VAKb/2lzZup/dk8Oswco0yi/NOUhf+Nitx9ExAW/ST1qvo7b6V3D8Vq+yXW4FfGheRwF72XzUOpusFdOHVtdShH9lL18Hvv6CUAxv/UjVL6NiCTjXKaKJazmcGbhwTVJOVUG7OmKPDfhmUC6SxhReYkawR3vAyBr8mKHveZD8=
condition: "$TRAVIS_OS_NAME = linux && $TRAVIS_GO_VERSION = '1.10'"
env:
global:
# travis encrypt --add GITHUB_TOKEN=$GITHUB_TOKEN
secure: JIsGOJapsU/oSyZX6fyCC+s8Jjlmmr7SAlP55KhUi1pZbQ18Saszs/zRo5Og+wPtwj5teikcSSYec9ZyuLnDX/j6N0LMkSMSldSCgR2lv9uQI1zmtUMjYTI44f9LgtHN6JvTjiH6zxW5HSZJta+4p6LjpxOYaUhA4A5FPGSHs6MF/kXtgA0ufc640GMzTrFcBrnVN4DXR1UlAqMnt9lQ2FgI+rJ1PfVDoho6m2Uz7XGsarYQSTm/l2sfEkNtCJjKDLEc0tEYCuCUUPnbhaJgQIlTpCo03dR30CoSArkkagNWfSYcKwoV+bBryHK08GNHvXtm3LarRPDe8MdN0a4TwC26boUjYtQfrabI0Q7d1EhpXGSL0dNVwiakK76xwOi8b3UfBog5I3fB2u7R0HsiLhxQzf1GMTS6Vx41xAByomGMcXfg6pCxZ5Q/l2Xs/IepC6xMWHyTvFV8EDnRaECHJNPZPXdhvGSOzGOsRWM+eVcC8k67YovTS9bzcaVEMFDZ+5SO91YX2dKstUhEt6T/b6pRktc0+herk4iUicMT9E9G1I/l9Zyz6reFW3XioPqt53uYq5O3jB4rDmbgiPdPKdayrufXZtV15GLTEG5AhVfG5/u/zafrHkzLftWLu23gLVfWLQ5CmpbFp2wZl4tYH+7uMKGFFWuX8ZkllojqozI=
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Direct downloads are available through the [releases page](https://github.com/rs
Using [homebrew](http://brew.sh/) on macOS (Go not required):

```
brew install https://github.com/rs/jaggr/releases/latest/homebrew.rb
brew install rs/tap/jaggr
```

From source:
Expand Down
8 changes: 8 additions & 0 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ import (
"github.com/rs/jaggr/aggr"
)

var version = "master"

func main() {
flag.Usage = func() {
out := os.Stderr
Expand All @@ -32,9 +34,15 @@ func main() {
fmt.Fprintln(out, " alias:")
fmt.Fprintln(out, " Optional name to use instead of the field path on the output.")
}
showVersion := flag.Bool("version", false, "Show version")
interval := flag.Duration("interval", time.Second, "Sampling interval")
flag.Parse()

if *showVersion {
println(version)
os.Exit(0)
}

if len(flag.Args()) == 0 {
flag.Usage()
os.Exit(1)
Expand Down
62 changes: 0 additions & 62 deletions release.sh

This file was deleted.

0 comments on commit 5f9ce33

Please sign in to comment.