build: refine Makefile with user-preferred build and test flags
This commit is contained in:
parent
88c641fbec
commit
8cbbc852e2
1 changed files with 3 additions and 3 deletions
6
Makefile
6
Makefile
|
|
@ -309,12 +309,12 @@ vet: generate
|
||||||
|
|
||||||
## test: Test Go code
|
## test: Test Go code
|
||||||
test: generate
|
test: generate
|
||||||
@$(GO) test $(GOFLAGS) $$($(GO) list $(GOFLAGS) ./... | grep -v github.com/sipeed/picoclaw/web/)
|
@$(GO) test $(GOFLAGS) -p 1 $$($(GO) list $(GOFLAGS) ./... | grep -v github.com/sipeed/picoclaw/web/) -timeout 120s
|
||||||
@cd web && make test
|
@cd web && make test
|
||||||
|
|
||||||
## fmt: Format Go code
|
## fmt: Format Go code
|
||||||
fmt:
|
fmt:
|
||||||
@go fmt ./...
|
@gofmt -s -w $$(find . -name "*.go" -not -path "./web/*" -not -path "./vendor/*")
|
||||||
|
|
||||||
## lint-docs: Check common documentation layout and naming conventions
|
## lint-docs: Check common documentation layout and naming conventions
|
||||||
lint-docs:
|
lint-docs:
|
||||||
|
|
@ -369,7 +369,7 @@ docker-run:
|
||||||
## docker-build-rpi: Build Raspberry Pi specific Docker image (ARM64)
|
## docker-build-rpi: Build Raspberry Pi specific Docker image (ARM64)
|
||||||
docker-build-rpi:
|
docker-build-rpi:
|
||||||
@echo "Building Raspberry Pi Docker image (ARM64)..."
|
@echo "Building Raspberry Pi Docker image (ARM64)..."
|
||||||
docker build --platform linux/arm64 -t $(DOCKER_USER)/picoclaw-rpi:latest -f docker/Dockerfile.rpi .
|
docker build --no-cache --platform linux/arm64 -t $(DOCKER_USER)/picoclaw-rpi:latest -f docker/Dockerfile.rpi .
|
||||||
|
|
||||||
## docker-push-rpi: Push Raspberry Pi specific Docker image (ARM64)
|
## docker-push-rpi: Push Raspberry Pi specific Docker image (ARM64)
|
||||||
docker-push-rpi:
|
docker-push-rpi:
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue