From 013fe608a00be5c56d9dc9696c5cf8542d0c5736 Mon Sep 17 00:00:00 2001 From: Dave Reisner Date: Sun, 13 May 2012 15:35:16 -0400 Subject: lsinitcpio: Always show extraction time Even for uncompressed images, estimate the work being done to extract to ramfs. Signed-off-by: Dave Reisner --- lsinitcpio | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lsinitcpio b/lsinitcpio index 6cb9b07..9cb5209 100755 --- a/lsinitcpio +++ b/lsinitcpio @@ -135,8 +135,8 @@ if (( analyze )); then zsize=$(stat -c %s "$image") # calculate compression ratio + TIMEFORMAT=%R decomptime=$({ time decomp "$image" >/dev/null; } 2>&1 ) if [[ $compress ]]; then - TIMEFORMAT=%R decomptime=$({ time decomp "$image" >/dev/null; } 2>&1 ) fullsize=$(decomp "$image" | bsdtar xOf - | wc -c) ratio=.$(( zsize * 1000 / fullsize % 1000 )) fi @@ -181,8 +181,8 @@ if (( analyze )); then if [[ $compress ]]; then msg 'Compressed with: %s' "$compress" msg2 'Uncompressed size: %s (%s ratio)' "$(size_to_human "$fullsize")" "$ratio" - msg2 'Estimated decompression time: %ss' "$decomptime" fi + msg2 'Estimated extraction time: %ss' "$decomptime" printf '\n' if (( ${#modules[*]} )); then -- cgit v1.2.3-24-g4f1b