Skip to content

Instantly share code, notes, and snippets.

View heronyang's full-sized avatar
😶
No Regrets

Heron Yang heronyang

😶
No Regrets
View GitHub Profile
#!/bin/bash
if [ -z "$1" ]; then
echo "Usage: sudo $0 /dev/sdh1"
exit 1;
fi
dd if=$1 of=/dev/null & pid=$!
while true; do
ps -p$pid --no-heading || break;
echo "-- $(date) ------------------";