Skip to content

Commit

Permalink
Set up releases with TravisCI
Browse files Browse the repository at this point in the history
  • Loading branch information
abulimov committed Apr 5, 2016
1 parent 007e32c commit d58ccc2
Show file tree
Hide file tree
Showing 4 changed files with 32 additions and 5 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@
# built executable
haproxy-linter

# releases
release

# Compiled Object files, Static and Dynamic libs (Shared Objects)
*.o
*.a
Expand Down
16 changes: 14 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,21 @@
language: go

go:
- 1.5
- 1.6
- tip

notifications:
email: false
before_deploy:
- make release
deploy:
provider: releases
api_key:
secure: SdxwPXYq4mMYNJLMcYxSexAO3woYDYGDh0az2mZMwas6guaax3YyBT+PcTt1DcYKJXGlSNOOED9qLAp8BE+M+ehRVUMNs5Kp+i+gnMh0izvLTpmVW19sMpPvGiueL181FHwgiRuGetQGxxCiPuoZVwnhVsXRWhita9wQ6570HPLzRiDyCQd07/2WV4ogQD82axBQjBByYGJtEwwndmvEIuQb4RqjzDWYEoTh8pgD24RxvYcvbx3WXOmy6GSHf6oeDg+Zira1HZK3tuPZ1JogApuI/vfUF8CglTc6D1wac/HtrYPgoNmJMLbgiPYcjtF04X1mUTjU/Yb5WfzIedJMBaNsFWN7nq4xo8XmS3YLniHtv410ZwlLZxa2fiB2+1844GElLF7/hAgDj9tyFHwG7V7Rynz2nrryuxd0VcqhcinpQVvQKB0tQXRHKkGuxkUigeZjutn1li4eo9ZuAqr1Pz6RPYWey5yeDugxyEXYDzWH/xivFboihsSlmzYeWfEYTGENsQNqclHDrjp7FFMUrDVfy4ZVQ8k6wdsdc5fJnjI8aH+m6cFwP9QFg7Vy7MOXFkm8B+0MocVzHNKz05kgtvWE7mYu0RTDbgamYpueyyHDtLsjSSAqzhXzBpyGjcgGYFIuDf5wRkSgushLB54KjHOOMYJrOkz29FFcTKhK9t0=
file:
- release/haproxy-lint.darwin-amd64.zip
- release/haproxy-lint.linux-amd64.zip
- release/haproxy-lint.linux-arm.zip
on:
repo: abulimov/haproxy-lint
tags: true
go: 1.6
12 changes: 9 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.PHONY: all test clean build linux
.PHONY: all test clean build linux release

GOFLAGS ?= $(GOFLAGS:)
GOOS ?= linux
Expand All @@ -11,8 +11,14 @@ all: test
get:
@go get $(GOFLAGS) -t ./...

linux: get
@GOOS=$(GOOS) GOARCH=$(GOARCH) CGO_ENABLED=$(CGO_ENABLED) go build $(GOFLAGS) $(REPO)
release:
mkdir -p release
GOOS=linux GOARCH=amd64 go build -o haproxy-lint $(REPO)
zip -0 release/haproxy-lint.linux-amd64.zip haproxy-lint
GOOS=linux GOARCH=arm go build -o haproxy-lint $(REPO)
zip -0 release/haproxy-lint.linux-arm.zip haproxy-lint
GOOS=darwin GOARCH=amd64 go build -o haproxy-lint $(REPO)
zip -0 release/haproxy-lint.darwin-amd64.zip haproxy-lint

build: get
go build $(GOFLAGS) $(REPO)
Expand Down
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,12 @@ Simple linter for [HAProxy](http://haproxy.org) configuration.

## Installation

Grab latest release on [releases page](https://github.com/abulimov/haproxy-lint/releases),
or build from source.

### Building from source

You need working Go compiler.
Tested against Go 1.5+

On Linux/OSX:
Expand Down

0 comments on commit d58ccc2

Please sign in to comment.