mirror of
https://github.com/yudai/gotty.git
synced 2026-01-08 18:48:50 +01:00
Update make test to include tsfmt
This commit is contained in:
parent
19aa6f3aaa
commit
765000bd61
3 changed files with 163 additions and 2 deletions
10
Makefile
10
Makefile
|
|
@ -1,5 +1,5 @@
|
|||
OUTPUT_DIR = ./builds
|
||||
GIT_COMMIT = `git rev-parse HEAD | cut -c1-7`
|
||||
GIT_COMMIT = $$(git rev-parse HEAD | cut -c1-7)
|
||||
VERSION = 3.0.0-alpha.1
|
||||
BUILD_OPTIONS = -ldflags "-X main.Version=$(VERSION) -X main.CommitID=$(GIT_COMMIT)"
|
||||
|
||||
|
|
@ -70,8 +70,14 @@ tools:
|
|||
go get github.com/mitchellh/gox # for crosscompiling
|
||||
go get github.com/tcnksm/ghr # for making gihub releases
|
||||
|
||||
.PHONY: test
|
||||
test:
|
||||
if [ `go fmt $(go list ./... | grep -v /vendor/) | wc -l` -gt 0 ]; then echo "go fmt error"; exit 1; fi
|
||||
if [ $$(go fmt $$(go list ./...) | wc -l) -gt 0 ]; then echo "go fmt error"; exit 1; fi
|
||||
cd js && npx tsfmt -r --verify
|
||||
|
||||
.PHONY: fmt
|
||||
tsfmt:
|
||||
cd js && npx tsfmt -r
|
||||
|
||||
cross_compile:
|
||||
GOARM=5 gox -os="darwin linux freebsd netbsd openbsd" -arch="386 amd64 arm" -osarch="!darwin/arm" -output "${OUTPUT_DIR}/pkg/{{.OS}}_{{.Arch}}/{{.Dir}}"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue