diff options
author | Daniel Friesel <derf@derf.homelinux.org> | 2008-08-02 15:01:40 +0200 |
---|---|---|
committer | Daniel Friesel <derf@derf.homelinux.org> | 2008-08-02 15:01:40 +0200 |
commit | 1b5b64b0dffda7c538b005e9edfebf9c23bc2a7c (patch) | |
tree | 8f4003ed09d019dbb458e62389b0b533ee35bdf7 | |
parent | 4badb1b79d438acde2a2440d3b9dabd4ecad75bd (diff) |
bin/pkg: Optimized clear_line, added colors to progress
-rwxr-xr-x | bin/pkg | 9 |
1 files changed, 5 insertions, 4 deletions
@@ -35,11 +35,12 @@ check_valid () { } clear_line () { - echo -ne "\r" + string="\r" for char in {0..80}; { - echo -ne " " + string+=" " } - echo -ne "\r" + string+="\r" + echo -ne $string } # Read local configuration @@ -137,7 +138,7 @@ progress () { clear_line c=$[$currentper/5] a=$[20-$c] - say "$desc [" + say "${info}$desc${reset} [" item $c '=' item $a ' ' say "] $currentper% $desc2" |