change the method run tasks on Windows