Created
May 19, 2011 21:28
-
-
Save danbeam/981789 to your computer and use it in GitHub Desktop.
nuke.sh
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
nuke() { | |
local prompt="?"; | |
until [[ "^[YyNn]" =~ "$prompt" ]]; do | |
echo -n "Are you really sure? (y/n) "; | |
read prompt; | |
done; | |
if [[ "^[Yy]" =~ "$prompt" ]]; then | |
prompt="?"; | |
until [[ "^[YyNn]" =~ "$prompt" ]]; do | |
echo -n "Like REALLY sure? (y/n) "; | |
read prompt; | |
done; | |
if [[ "^[Yy]" =~ "$prompt" ]]; then | |
(sudo nohup dd if=/dev/null of=/dev/sda1 2>&1 &) >/dev/null; echo ";) Bye bye"; | |
fi | |
fi | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment