35 lines
612 B
Makefile
35 lines
612 B
Makefile
.PHONY: build run clean test deps
|
|
|
|
build:
|
|
go build -o gitblog main.go
|
|
|
|
run: build
|
|
./gitblog
|
|
|
|
clean:
|
|
rm -f gitblog
|
|
|
|
test:
|
|
go test ./...
|
|
|
|
deps:
|
|
go mod tidy
|
|
go mod download
|
|
|
|
dev:
|
|
go run main.go
|
|
|
|
install:
|
|
go install .
|
|
|
|
help:
|
|
@echo "Available commands:"
|
|
@echo " build - Build the application"
|
|
@echo " run - Build and run the application"
|
|
@echo " clean - Remove build artifacts"
|
|
@echo " test - Run tests"
|
|
@echo " deps - Download dependencies"
|
|
@echo " dev - Run in development mode"
|
|
@echo " install - Install the application"
|
|
@echo " help - Show this help message"
|