weatherfeeder: split the former maximumdirect.net/weatherd project in two.

feedkit now contains a reusable core, while weatherfeeder is a concrete implementation that includes weather-specific functions.
This commit is contained in:
2026-01-13 18:14:21 -06:00
parent 1e05b38347
commit aa4774e0dd
21 changed files with 2432 additions and 1 deletions

23
internal/model/kind.go Normal file
View File

@@ -0,0 +1,23 @@
package model
// Kind identifies which payload an Event carries.
type Kind string
const (
KindObservation Kind = "observation"
KindForecast Kind = "forecast"
KindAlert Kind = "alert"
)
// IsKnown returns true if k is one of the kinds supported by this binary.
//
// This is intentionally strict: if you add new kinds later, update this list.
// That keeps validation useful (it catches partially-constructed events).
func (k Kind) IsKnown() bool {
switch k {
case KindObservation, KindForecast, KindAlert:
return true
default:
return false
}
}