Language: Shell Script (Bash), Submitted: 3/09/10, Country: United States - Raw | DownloadBack to the main page
become_root_or_fail()
{
    if [ ! -w /root ]; then
        echo "You have to be root to use $0" >&2
        exit 1
    fi
    cleanup_and_exit 1
}