That got garbaged when I posted it, interestingly. Something about this wordpress interface, I fear.

The important bit is ending the line with << EOF and the hash-bang line is the first line of the script, not part of the cat command.