Fix task for Darwin OS

OS X identifies itself as darwin, which means the condition /win/.test(process.platform) passes in the current form. This patch fixes this behaviour.