kevva / download

Download and extract files
MIT License
1.28k stars 200 forks source link

global process events #39

Closed piranna closed 9 years ago

piranna commented 9 years ago

When downloading several files at a time, the progress callback (for example when using download-status) should notify the progress globally instead of for each individual download progress.

kevva commented 9 years ago

Might be hard to do since everything is done concurrently, i.e all files is downloaded at the same time.

piranna commented 9 years ago

Now that several files can be downloaded concurrently and there's a global tasks array, maybe each one of the downloads instead of emit the events themselves would emit them internally, being the Download manager that listen to them and emit the progress events for the total of them.

kevva commented 9 years ago

Still trying to figure out how to do this now that I'm using got instead of request.

piranna commented 9 years ago

Yes, I've also seen that you removed the events so download-status could be used... :-/

piranna commented 9 years ago

This is still happening in 4.1.0.

kevva commented 9 years ago

Yes, I don't think I'll add global events in the near future.

piranna commented 9 years ago

If it's not possible to have a global progress bar, one for each download would be a good thing, although dificult. It could be done by using store & restore cursor position commands.

floatdrop commented 9 years ago

Wat. :horse:

piranna commented 9 years ago

Cool, I'll try it later.