Skip to content

Commit

Permalink
trying to split up the package target on travis
Browse files Browse the repository at this point in the history
  • Loading branch information
s1cyan committed Oct 22, 2019
1 parent cc26b4f commit 7966a1d
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 3 deletions.
18 changes: 16 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,24 @@ jobs:
name: Unit Test on Windows
os: windows
# script: make unittest
- name: Deploy Release
- name: Deploy Release osx
stage: deploy
os: osx
script:
- make VERSION=${TRAVIS_TAG} package-osx
- make deploy
deploy:
provider: releases
skip_cleanup: true
api_key: "$GITHUB_OAUTH_TOKEN"
file: package/*
file_glob: true
on:
branch: master
tags: true
- name: Deploy Release win/linux
stage: deploy
os: linux
script:
- make VERSION=${TRAVIS_TAG} package
- make deploy
Expand All @@ -66,4 +81,3 @@ jobs:
on:
branch: master
tags: true

4 changes: 3 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -80,9 +80,11 @@ build-linux build-darwin build-windows: ## Build the binary of the respective op
GOOS=$(os) GOARCH=amd64 go build -o $(BUILD_PATH)/$(build_binary) -ldflags "-X main.VERSION=$(VERSION)"

.PHONY: package
package: tar-darwin tar-windows tar-linux ## Creates packages for all operating systems and store them in package/ dir
package: tar-windows tar-linux ## Creates packages for all operating systems and store them in package/ dir
# package: tar-linux deb-linux rpm-linux tar-darwin brew-darwin tar-windows ## Creates packages for all operating systems and store them in package/ dir

package-osx: tar-darwin

.PHONY: tar-linux
tar-linux: build-linux ## Build the linux binary and package it in a .tar file
.PHONY: tar-darwin
Expand Down

0 comments on commit 7966a1d

Please sign in to comment.