Fix encoding for reals.

I'm an idiot. Windows has this tendency to try to execute
programs/batch files even when the extension is missing. Previously,
the script was attempting to execute the encoding script with the
extension missing, which worked dandy on windows (until it attemtped to
delete itself, that is) but failed miserably on any reasonable
operating system.

I've rectified this by using as many anonymous tables as possible in
order to remove a whopping one if statement. The readabilty of the code
is sure to suffer greatly from this "improvement"!

Autours Nose: running the script under a spawned sh does not
necessarily carry over the PATH of whatever shell the user is
accustomed to using, and therefore it's highly recommended to use the
absolute path to the encoding binary rather than relying on PATH.