Skip to content

Commit

Permalink
Add Makefile: make dist, make test, make build
Browse files Browse the repository at this point in the history
  • Loading branch information
VojtechVitek committed Aug 26, 2019
1 parent 5ddf348 commit 38252cc
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
.PHONY: all build dist test install

build:
@mkdir -p ./bin && rm -f ./bin/*
go build -o ./bin/yaml ./cmd/yaml

dist:
@mkdir -p ./bin && rm -f ./bin/*
GOOS=darwin GOARCH=amd64 go build -o ./bin/yaml-darwin64 ./cmd/yaml
GOOS=linux GOARCH=amd64 go build -o ./bin/yaml-linux64 ./cmd/yaml
GOOS=linux GOARCH=386 go build -o ./bin/yaml-linux386 ./cmd/yaml
GOOS=windows GOARCH=amd64 go build -o ./bin/yaml-windows64.exe ./cmd/yaml
GOOS=windows GOARCH=386 go build -o ./bin/yaml-windows386.exe ./cmd/yaml

test:
go test ./...

install:
go install ./cmd/sup

0 comments on commit 38252cc

Please sign in to comment.