half-assed fix for newlines in tidepool
This commit is contained in:
parent
6e7d6213aa
commit
c8c2573e30
|
@ -77,7 +77,7 @@ fn single(args: SingleRun) -> Result<()> {
|
|||
|
||||
match msg {
|
||||
Msg::Interrupt => {
|
||||
eprintln!("\ncaught interrupt.");
|
||||
eprint!("\ncaught interrupt.");
|
||||
exit_early.store(true, atomic::Ordering::Relaxed);
|
||||
}
|
||||
Msg::Heartbeat(_id) => {
|
||||
|
@ -98,6 +98,8 @@ fn single(args: SingleRun) -> Result<()> {
|
|||
// be sent so the ctrl-c handler will abort the program
|
||||
std::mem::drop(rx);
|
||||
|
||||
eprintln!();
|
||||
|
||||
if !output.did_complete() && !prompt_yn(&args.io, "run did not finish, keep it?") {
|
||||
break;
|
||||
}
|
||||
|
@ -140,7 +142,7 @@ fn multi(args: MultiRun) -> Result<()> {
|
|||
tracing::trace!(msg = debug(&msg));
|
||||
match msg {
|
||||
Msg::Interrupt => {
|
||||
eprintln!("\ncaught interrupt.");
|
||||
eprint!("\ncaught interrupt.");
|
||||
tasks.store(0, atomic::Ordering::Relaxed);
|
||||
exit_early.store(true, atomic::Ordering::Relaxed);
|
||||
}
|
||||
|
@ -175,9 +177,7 @@ fn multi(args: MultiRun) -> Result<()> {
|
|||
}
|
||||
}
|
||||
|
||||
if !args.io.quiet {
|
||||
eprintln!();
|
||||
}
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
@ -268,12 +268,8 @@ fn print_single_progress(io_args: &IoArgs, status: &Status, goal: usize) -> std:
|
|||
"] {cleared}/{goal} #{pieces}, {pps:.2} pps, {pace} pace"
|
||||
)?;
|
||||
|
||||
if cleared == goal {
|
||||
writeln!(writer)
|
||||
} else {
|
||||
write!(writer, " ")?;
|
||||
writer.flush()
|
||||
}
|
||||
}
|
||||
|
||||
fn print_multi_progress(
|
||||
|
|
Loading…
Reference in New Issue