Bash instead of PHP

Found this script via Google. Liked it. Improved it by removing the PHP part.