Add configuration and CLI foundation

This commit is contained in:
2026-05-29 16:58:18 +00:00
parent e5cd23de48
commit 8c065751c2
19 changed files with 1068 additions and 43 deletions

53
internal/app/app.go Normal file
View File

@@ -0,0 +1,53 @@
// Package app owns application orchestration and top-level use cases.
package app
import (
"context"
"fmt"
"time"
"gitea.maximumdirect.net/eric/weatherreporter/internal/config"
)
type ReportKind string
const (
ReportDaily ReportKind = "daily"
ReportTomorrow ReportKind = "tomorrow"
ReportThreeDay ReportKind = "three-day"
ReportWeekend ReportKind = "weekend"
ReportStorm ReportKind = "storm"
)
type BatchKind string
const (
BatchMorning BatchKind = "morning"
BatchEvening BatchKind = "evening"
)
type GenerateRequest struct {
Config config.Config
Report ReportKind
OutputPath string
Date time.Time
StormStart time.Time
StormEnd time.Time
}
type BatchRequest struct {
Config config.Config
Batch BatchKind
}
func Generate(ctx context.Context, req GenerateRequest) error {
_ = ctx
_ = req
return fmt.Errorf("generate is not implemented")
}
func RunBatch(ctx context.Context, req BatchRequest) error {
_ = ctx
_ = req
return fmt.Errorf("run is not implemented")
}

View File

@@ -1,2 +0,0 @@
// Package app owns application orchestration and top-level use cases.
package app