MCPcopy Create free account
hub / github.com/buttplugio/buttplug / read_line

Function read_line

examples/src/bin/application.rs:25–32  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

23use tokio::io::{self, AsyncBufReadExt, BufReader};
24
25async fn read_line() -> String {
26 BufReader::new(io::stdin())
27 .lines()
28 .next_line()
29 .await
30 .unwrap()
31 .unwrap_or_default()
32}
33
34async fn wait_for_input() {
35 let _ = read_line().await;

Callers 2

wait_for_inputFunction · 0.85
mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected