Port code from Cargo and use for progress

A lot of its functionality is unused still, but the goal it to slowly
migrate logging functionality to it. There is also a useful progress bar
which can be ported over later - it depends on this module.

4c1fa54d10/src/cargo/util/progress.rs
This commit is contained in:
Ryan Dahl 2019-05-30 11:07:58 -04:00
parent 89216c7baa
commit 3a4d88475b
12 changed files with 554 additions and 32 deletions

View file

@ -647,9 +647,7 @@ fn fetch_remote_source_async(
) -> impl Future<Item = Option<ModuleMetaData>, Error = DenoError> {
use crate::http_util::FetchOnceResult;
let download_job = deno_dir
.progress
.add(format!("Downloading {}", module_name));
let download_job = deno_dir.progress.add("Download", module_name);
let module_name = module_name.to_owned();
let filepath = filepath.to_owned();