diff options
Diffstat (limited to 'scripts/contrib/ddimage')
-rwxr-xr-x | scripts/contrib/ddimage | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/scripts/contrib/ddimage b/scripts/contrib/ddimage index a503f11d0d..ab929957a5 100755 --- a/scripts/contrib/ddimage +++ b/scripts/contrib/ddimage @@ -100,5 +100,9 @@ if [ "$RESPONSE" != "y" ]; then fi echo "Writing image..." -dd if="$IMAGE" of="$DEVICE" bs="$BLOCKSIZE" +if which pv >/dev/null 2>&1; then + pv "$IMAGE" | dd of="$DEVICE" bs="$BLOCKSIZE" +else + dd if="$IMAGE" of="$DEVICE" bs="$BLOCKSIZE" +fi sync |