Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Example Makefile for small projects in golang
PACKAGES := \
github.com/eliasson/foo \
github.com/eliasson/bar
DEPENDENCIES := github.com/eliasson/acme
all: build silent-test
build:
go build -o bin/foo main.go
test:
go test -v $(PACKAGES)
silent-test:
go test $(PACKAGES)
format:
go fmt $(PACKAGES)
deps:
go get $(DEPENDENCIES)
@kanapuli

This comment has been minimized.

Copy link

commented Jun 4, 2018

Simple and clear. Helped a lot

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.