mirror of
https://codeberg.org/Cyborus/forgejo-cli.git
synced 2024-11-10 03:59:31 +01:00
fix: print message before reading in readline
This commit is contained in:
parent
23a345f5b3
commit
45ad1d81b9
1 changed files with 2 additions and 1 deletions
|
@ -136,8 +136,9 @@ async fn update_msg(check: bool) -> eyre::Result<()> {
|
|||
}
|
||||
|
||||
async fn readline(msg: &str) -> eyre::Result<String> {
|
||||
use std::io::Write;
|
||||
print!("{msg}");
|
||||
tokio::io::stdout().flush().await?;
|
||||
std::io::stdout().flush()?;
|
||||
tokio::task::spawn_blocking(|| {
|
||||
let mut input = String::new();
|
||||
std::io::stdin().read_line(&mut input)?;
|
||||
|
|
Loading…
Reference in a new issue