Skip to main content

Module confirmation

Module confirmation 

Source
Expand description

Confirmation I/O primitives.

This module owns the mechanics of asking a human to confirm an action by typing a specific token back — it does not decide which operations require confirmation. That is business/product confirmation policy and belongs in the consuming application layer, never here.

Functions§

confirm_typed
Write prompt to writer, flush it, read one line from reader, and report whether the trimmed input equals expected.