jx/Makefile
Matthew Rich d6c2679416
Some checks failed
Declarative Tests / test (push) Waiting to run
Lint / golangci-lint (push) Has been cancelled
add rpm spec
2024-05-26 02:05:18 -07:00

17 lines
485 B
Makefile

LDFLAGS?=--ldflags '-extldflags "-static"' --ldflags="-X 'main.commit=$(shell git rev-parse HEAD)' -X 'main.version=$(shell git describe --tags)' -X 'main.date=$(shell date '+%Y-%m-%d %T.%s%z')'"
export CGO_ENABLED=1
.PHONY=jx-cli
build: jx-cli
jx-cli:
go build -o jx $(LDFLAGS) ./cmd/cli/main.go
test: jx-cli
go test -coverprofile=artifacts/coverage.profile ./...
go tool cover -html=artifacts/coverage.profile -o artifacts/code-coverage.html
rpm:
rpmbuild -ba build/jx.spec