- Add a new test to ensure that all services are initialized correctly. - Add a new `preview-docker` target to the `Makefile` to make it easier to build and run the application in Docker. - Fix a bug that was causing the application to run twice when run in Docker. - Fix a bug that was preventing the digest from being run on startup. - Add logging to the `digestJob` to indicate the source of the job (startup or scheduler). - Fix a bug that was causing the `EmailTemplate` to be `nil`. - Rename `ProcessAndSendDigest` to `ProcessDigest` to more accurately reflect its function. - Make email sending conditional on SMTP configuration. - Add a concise log message for each digest produced, including entry count, output folder, and email sending status. Reviewed-on: #52
38 lines
753 B
Makefile
38 lines
753 B
Makefile
build:
|
|
go build -mod=vendor -o miniflux-digest ./cmd/miniflux-digest
|
|
|
|
preview:
|
|
@trap "exit 0" INT; go run -mod=vendor ./scripts/preview/main.go
|
|
|
|
preview-html:
|
|
go run -mod=vendor ./scripts/preview/main.go --html
|
|
|
|
preview-email:
|
|
go run -mod=vendor ./scripts/preview/main.go --email
|
|
|
|
preview-miniflux:
|
|
go run -mod=vendor ./scripts/preview/main.go --miniflux
|
|
|
|
preview-email-miniflux:
|
|
go run -mod=vendor ./scripts/preview/main.go --email --miniflux
|
|
|
|
test:
|
|
go test -mod=vendor ./... ./cmd/miniflux-digest
|
|
|
|
test-coverage:
|
|
./scripts/check-coverage.sh 60
|
|
|
|
test-coverage-full:
|
|
./scripts/check-coverage.sh --mode=functions 60
|
|
|
|
lint:
|
|
golangci-lint run
|
|
|
|
vendor:
|
|
go mod vendor
|
|
|
|
all: ci build
|
|
|
|
preview-docker:
|
|
@trap "exit 0" INT; docker compose up --build
|