Update Makefile to include linting in build, test, and test-race targets
- Added `lint` as a prerequisite for the `build`, `test`, and `test-race` targets to ensure code quality checks are performed before executing tests and builds. - This enhancement promotes better code hygiene and consistency across the development workflow.
This commit is contained in:
@@ -4,14 +4,14 @@ run: ## Run the application (cross-platform; uses go run for dev on Linux/macOS/
|
||||
run-debug: ## Run the application with debug logging (cross-platform)
|
||||
@go run . --log-level debug
|
||||
|
||||
build: deps ## Build a snapshot of the application for the current platform (uses -short for fast feedback)
|
||||
build: deps lint ## Build a snapshot of the application for the current platform (uses -short for fast feedback)
|
||||
@go test -short -v ./...
|
||||
@goreleaser build --single-target --snapshot --clean
|
||||
|
||||
test: deps ## Run all tests
|
||||
test: deps lint ## Run all tests
|
||||
@go test -shuffle=on -timeout=5m -v ./...
|
||||
|
||||
test-race: deps ## Run all tests with the race detector
|
||||
test-race: deps lint ## Run all tests with the race detector
|
||||
@go test -race -shuffle=on -timeout=5m -v ./...
|
||||
|
||||
lint: deps check-review-labels ## Run golangci-lint + review label hygiene check
|
||||
|
||||
Reference in New Issue
Block a user