diff --git a/change/react-native-windows-2020-05-13-14-16-07-rnw-dep-dontexit.json b/change/react-native-windows-2020-05-13-14-16-07-rnw-dep-dontexit.json new file mode 100644 index 00000000000..bf1bca20445 --- /dev/null +++ b/change/react-native-windows-2020-05-13-14-16-07-rnw-dep-dontexit.json @@ -0,0 +1,8 @@ +{ + "type": "prerelease", + "comment": "don't exit the powershell session and pause for keyboard input if interactive", + "packageName": "react-native-windows", + "email": "asklar@microsoft.com", + "dependentChangeType": "patch", + "date": "2020-05-13T21:16:07.200Z" +} diff --git a/vnext/Scripts/rnw-dependencies.ps1 b/vnext/Scripts/rnw-dependencies.ps1 index d91ee41d40d..c274c09006f 100644 --- a/vnext/Scripts/rnw-dependencies.ps1 +++ b/vnext/Scripts/rnw-dependencies.ps1 @@ -145,9 +145,11 @@ foreach ($req in $requirements) } if ($NeedsRerun) { - Write-Output "Some dependencies are not met. Re-run with -Install to install them."; - exit 1; + Write-Error "Some dependencies are not met. Re-run with -Install to install them."; + if (!$NoPrompt) { + [System.Console]::ReadKey(); + } + throw; } else { Write-Output "All mandatory requirements met"; - exit 0; }