forked from flavorjones/irc-notification-resource
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
34 lines (23 loc) · 828 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
ARTIFACTS_DIR=artifacts
default: test
all: test docker
test: artifacts integration_test.sh
cd cmd/out && go test
./integration_test.sh
artifacts: $(ARTIFACTS_DIR)/check $(ARTIFACTS_DIR)/in $(ARTIFACTS_DIR)/out
$(ARTIFACTS_DIR)/check: cmd/check/check.go
go get -d -t ./cmd/$(shell basename $@)
go build -o $@ ./cmd/$(shell basename $@)
$(ARTIFACTS_DIR)/in: cmd/in/in.go
go get -d -t ./cmd/$(shell basename $@)
go build -o $@ ./cmd/$(shell basename $@)
$(ARTIFACTS_DIR)/out: cmd/out/out.go
go get -d -t ./cmd/$(shell basename $@)
go build -o $@ ./cmd/$(shell basename $@)
docker: Dockerfile
docker build -t flavorjones/irc-notification-resource .
docker-push: docker
docker push flavorjones/irc-notification-resource
clean:
rm -rf $(ARTIFACTS_DIR)
.PHONY: default all test artifacts docker docker-push clean