Send Storm Alert Email
send_storm_alert.RdMain orchestrator: fetches forecasts, detects storms, and sends an email alert if gale-force winds are forecast. If no storms are detected, no email is sent. Uses the same Gmail SMTP pattern as the weekly email report.
Usage
send_storm_alert(
threshold_knots = NULL,
recipient = Sys.getenv("GMAIL_USERNAME"),
sender = Sys.getenv("GMAIL_USERNAME"),
dry_run = FALSE
)Value
List with: status ("sent", "no_storms", "preview", "error"), n_storms, stations_affected, preview_file (if dry_run), error (if failed).