Skip to content

Commit

Permalink
Migrate to Go modules
Browse files Browse the repository at this point in the history
  • Loading branch information
cbroglie committed Dec 23, 2019
1 parent f84b224 commit 9c31b21
Show file tree
Hide file tree
Showing 184 changed files with 11,481 additions and 13,458 deletions.
4 changes: 3 additions & 1 deletion .gitignore
Expand Up @@ -10,4 +10,6 @@ _obj
_test
_testmain.go
*.swp
coverage.txt
coverage.txt
/bin
/dist
7 changes: 6 additions & 1 deletion .goreleaser.yml
@@ -1,5 +1,10 @@
env:
- GO111MODULE=on
- CGO_ENABLED=1
- GOFLAGS=-mod=vendor
- GOPROXY=off
builds:
- main: ./cmd/mustache/main.go
- main: ./cmd/mustache
binary: mustache
goos:
- windows
Expand Down
30 changes: 18 additions & 12 deletions Makefile
@@ -1,9 +1,14 @@
export GOFLAGS := -mod=vendor

.PHONY: all
all: fmt vet lint test
all: bin/mustache

.PHONY: clean
clean:
rm -rf bin

.PHONY:
get-deps:
go get github.com/golang/lint/golint
.PHONY: ci
ci: fmt lint test

.PHONY: test
test:
Expand All @@ -13,13 +18,14 @@ test:
fmt:
go fmt ./...

.PHONY: vet
vet:
go vet ./...

.PHONY: lint
lint:
golint ./...
lint: bin/golint
go list ./... | xargs -L1 ./bin/golint -set_exit_status

.PHONY: ci
ci: fmt vet test
bin/golint: $(shell find . -type f -name '*.go')
@mkdir -p $(dir $@)
go build -o $@ ./vendor/golang.org/x/lint/golint

bin/%: $(shell find . -type f -name '*.go')
@mkdir -p $(dir $@)
go build -o $@ ./cmd/$(@F)
21 changes: 0 additions & 21 deletions cmd/mustache/vendor/github.com/spf13/cobra/.travis.yml

This file was deleted.

194 changes: 0 additions & 194 deletions cmd/mustache/vendor/github.com/spf13/cobra/bash_completions_test.go

This file was deleted.

94 changes: 0 additions & 94 deletions cmd/mustache/vendor/github.com/spf13/cobra/cobra/README.md

This file was deleted.

0 comments on commit 9c31b21

Please sign in to comment.