minor fixes to the code to make it work through cygwin because the ruby platform value is different when running it through different utilities