mirror of
https://github.com/shazow/ssh-chat.git
synced 2025-09-23 03:17:58 -04:00
fix makefile and use after_success
This commit is contained in:
parent
a97d7c0168
commit
a01c286666
@ -19,12 +19,12 @@ go:
|
||||
script:
|
||||
# TODO: Bring this back: - fgt golint
|
||||
# - make test
|
||||
- make build
|
||||
- CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -ldflags "-X main.buildCommit `git describe --long --tags --dirty --always`" ./cmd/ssh-chat
|
||||
- ssh-keygen -f ~/.ssh/id_rsa -t rsa -N ''
|
||||
- cp ~/.ssh/id_rsa id_rsa
|
||||
- docker build -t "$DOCKER_USER"/ssh-chat:latest .
|
||||
|
||||
after_script:
|
||||
after_success:
|
||||
- test $TRAVIS_PULL_REQUEST == "false" && test $TRAVIS_BRANCH == "master"
|
||||
- docker login -e="$DOCKER_EMAIL" -u="$DOCKER_USER" -p="$DOCKER_PASS"
|
||||
- docker push $DOCKER_USER/ssh-chat:latest
|
||||
|
2
Makefile
2
Makefile
@ -7,7 +7,7 @@ SRCS = %.go
|
||||
all: $(BINARY)
|
||||
|
||||
$(BINARY): deps **/**/*.go **/*.go *.go
|
||||
CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -ldflags "-X main.buildCommit `git describe --long --tags --dirty --always`" ./cmd/ssh-chat
|
||||
go build -ldflags "-X main.buildCommit `git describe --long --tags --dirty --always`" ./cmd/ssh-chat
|
||||
|
||||
deps:
|
||||
go get ./...
|
||||
|
Loading…
x
Reference in New Issue
Block a user