Use 'which' on cmd before spawn to avoid erros on Windows