-i, --ignore Ignore temporary files from previous runs
-o, --no-order Do not check the build order
(Saves time, but may cause breakage.)
+ -P, --no-progress Turn off the progress meter
-q, --quiet Be less verbose (also passed to emerge command)
-v, --verbose Be more verbose
-u, --no-util UTIL Do not use features provided by UTIL
# i: current item
# n: total number of items to process
progress() {
- if [[ $quiet ]]; then
- progress() { :; }
- else
+ if [[ -t 1 ]]; then
progress() {
local curProg=$(( $1 * 100 / $2 ))
(( curProg == OLDPROG )) && return # no change, output nothing
echo -ne '\r \r'"[ $curProg% ] $lb"
}
progress $@
+ else # STDOUT is not a tty. Disable progress meter.
+ progress() { :; }
fi
}
# Usage: countdown n
-o|--no-order)
unset ORDER_PKGS
;;
+ -P|--no-progress)
+ progress() { :; }
-q|--quiet)
- echo_v() { : ; }
+ echo_v() { :; }
+ progress() { :; }
quiet=1
EMERGE_OPTIONS+=($1)
;;