Re: Patch to implement progress in dd
"Alfred M. Szmidt" <[email protected]> Sun, 25 May 2003 14:01:37 +0200
| Newsgroups | gmane.comp.gnu.fileutils.bugs |
|---|---|
| Message-ID | <[email protected]> |
>What would be nice is to add a --progress option to all file >related programs (cp, mv, rm, dd, etc). Hmm... Maybe thats a >project for next weekend. Have you made any progress on that? I haven't had a chance to look at it since my last discussion, but I'm going to have some time this weekend to work on various projects. Just want to make sure I'm not duplicating things you've already done. Actually, I forgot about this small weekend project. So just go ahead. But since I'm at it, I might just as well write what I would imagin this to look like; it is quite brief and without any real details. If you had something else in mind please tell us all. :) All the general code for the progress bar should be general. So that you don't get lots of duplicate code in mv/rm/cp/etc. As for the actual switch, I would actually like it to be the same as -v (or -vv , just something short). Personally, I don't like the idea of an progress "bar", but something less annoying. For example something like this: $ cp --progress foo.c bar.c foo.c -> bar.c [TOTAL-SIZE/AMOUNT-COPIED] Where TOTAL-SIZE is the total size of the file, and AMOUNT-COPIED is the amount that has been copied; which would get updated at specific intervals, say 2sec as default. --progress would also have an optional argument that would let the user specify how often to update AMOUNT-COPIED. As for how fast the file is being copied, I don't really see the point in that, since that can be calculated in your head quite quickly. What do you think?