Skip to content

sivaprasadreddy/bookmarks-go

Repository files navigation

Bookmarks Go

Tools

$ go install github.com/cosmtrek/air@latest
$ go install honnef.co/go/tools/cmd/staticcheck@latest

Run application

$ docker-compose up -d bookmarks-db
$ air

Run application using docker-compose

$ docker-compose up --build -d

Run tests

$ go test -v ./...

# Check coverage
$ GIN_MODE=release go test -v -coverprofile=coverage.out ./...
$ go tool cover -html=coverage.out

Build the application

$ go build -o ./bin/bookmarks cmd/bookmarks/main.go
$ ./bin/bookmarks
$ open http://localhost:8080