[pacman-dev] TotalDownload option.

Xilon xilonmu at gmail.com
Sat Nov 10 00:14:25 EST 2007


On Nov 10, 2007 9:54 AM, Nathan Jones <nathanj at insightbb.com> wrote:
> Ok, here's the updated version:
>
> $ sudo pacman -S gcc gcc-libs gcc-fortran
> resolving dependencies... done.
> looking for inter-conflicts... done.
>
> Targets: gcc-libs-4.2.2-2 [1.06 MB]  gcc-4.2.2-3 [8.92 MB]
>          gcc-fortran-4.2.2-1 [2.91 MB]
>
> Total Package Size:     12.89 MB
> Total Download Size:    12.89 MB
>
> Proceed with installation? [Y/n]
> :: Retrieving packages from core...
>  gcc-libs-4.2.2-2-i686   1081.1K  665.7K/s 00:00:02 [#####################]   8%
>  gcc-4.2.2-3-i686          10.0M 1009.0K/s 00:00:10 [#####################]  77%
> :: Retrieving packages from extra...
>  gcc-fortran-4.2.2-1-...   12.9M  926.2K/s 00:00:14 [#####################] 100%
> checking package integrity... done.
> (3/3) checking for file conflicts                   [#####################] 100%
> (1/3) upgrading gcc-libs                            [#####################] 100%
> (2/3) upgrading gcc                                 [#####################] 100%
> (3/3) upgrading gcc-fortran                         [#####################] 100%
>
>
>
> I changed the download callback function to take both the current file
> and the entire list xfered/totals, which gets rid of that done parameter
> and cleans up the code a bit. Graphical clients could probably use both
> since it's easier to draw two progress bars in a GUI.
>
> I haven't tested this code as much as my other patch so watch out for
> any bugs.
>
>
> _______________________________________________
> pacman-dev mailing list
> pacman-dev at archlinux.org
> http://archlinux.org/mailman/listinfo/pacman-dev
>

IMO it is a bit confusing to see the progress bar completed while the
percentage isn't 100%, especially when people don't expect this
behaviour. It would be better if there was some indication that the
percentage is the total progress. It would be best is there was a
"total" progress bar underneath or something, to actually separate
them, but that would probably require too many alterations to the code
for the little benefit it would give.




More information about the pacman-dev mailing list