Skip to content

Commit

Permalink
Auto merge of #6085 - alexcrichton:progress, r=ehuss
Browse files Browse the repository at this point in the history
Print a line per downloaded crate

This commit brings back the old one-line-per-crate output that Cargo's
had since the beginning of time but was removed in #6005. This was
requested on our [users forum][1]

[1]: https://internals.rust-lang.org/t/testing-cargos-parallel-downloads/8466/2
  • Loading branch information
bors committed Sep 24, 2018
2 parents b2b34ac + ef7e98f commit a0e3077
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/cargo/core/package.rs
Original file line number Diff line number Diff line change
Expand Up @@ -540,10 +540,10 @@ impl<'a, 'cfg> Downloads<'a, 'cfg> {
};

// If the progress bar isn't enabled then we still want to provide some
// semblance of progress of how we're downloading crates.
if !self.progress.borrow().as_ref().unwrap().is_enabled() {
self.set.config.shell().status("Downloaded", &dl.descriptor)?;
}
// semblance of progress of how we're downloading crates, and if the
// progress bar is enabled this provides a good log of what's happening.
self.progress.borrow_mut().as_mut().unwrap().clear();
self.set.config.shell().status("Downloaded", &dl.descriptor)?;

self.downloads_finished += 1;
self.downloaded_bytes += dl.total.get();
Expand Down

0 comments on commit a0e3077

Please sign in to comment.