diff --git a/src/ingest_gtfs_schedule/main.rs b/src/ingest_gtfs_schedule/main.rs index 566d975b..378d7617 100644 --- a/src/ingest_gtfs_schedule/main.rs +++ b/src/ingest_gtfs_schedule/main.rs @@ -238,6 +238,15 @@ async fn main() -> Result<(), Box> { .unwrap() .get::("softinsert"); + let forcewipe = arguments::parse(std::env::args()) + .unwrap() + .get::("forcewipe") + .unwrap_or_else(|| false); + + if (startfresh.unwrap_or(false) && isprod.unwrap_or(false) && forcewipe) { + panic!("Cannot wipe the prod server without --forcewipe true"); + } + let schemaname = match is_prod { Some(s) => { if s {