mirror of
https://github.com/taigrr/pastebin
synced 2026-04-05 02:42:30 -07:00
- Add MaxBytesReader to limit paste body size (1 MB) - Buffer template output before writing to prevent partial responses - Add paste ID collision retry logic - Update Dockerfile to use modern multi-stage build (remove go.rice) - Update Makefile to use direct go build commands - Add test for oversized paste rejection
18 lines
288 B
Makefile
18 lines
288 B
Makefile
.PHONY: build install test clean
|
|
|
|
all: build
|
|
|
|
build:
|
|
go build -o pastebin .
|
|
go build -o pb ./cmd/pb/
|
|
|
|
install:
|
|
go install .
|
|
go install ./cmd/pb/
|
|
|
|
test:
|
|
go test -v -cover -coverprofile=coverage.txt -covermode=atomic -coverpkg=./... -race ./...
|
|
|
|
clean:
|
|
rm -f pastebin pb coverage.txt
|