-
-
Notifications
You must be signed in to change notification settings - Fork 8
improve yarn/npm installers #36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
improve yarn/npm installers #36
Conversation
This should not be included since we support multiple package managers
No need to throw, PHP trace won't give any relevant output here. Just make clear what process failed. Error output is already echoed above.
|
|
||
| ensureDirSync(binaryDestDir); | ||
|
|
||
| console.log('FOOOOO') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lol. 😅
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I know 🫠 haha
| if ($result->failed()) { | ||
| echo PHP_EOL; | ||
| error("Command failed: '{$command}' (exit code {$result->exitCode()})"); | ||
| exit(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Include the exit code here in the parenthesis to ensure we don’t return exit 0 (success)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
good catch!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed in 7ed3679
|
Need one more review on this one @NativePHP/contributors |
|
Got chu. |
This PR fixes the
yarninstaller.Additionally it now throws an error when a
install,runorbuildcommand fails, no longer failing silently.Removed
packageManagersentry frompackage.jsonThis should not be included since we support multiple package managers
Fixes Run the NativePHP installer with pnpm doesn't work. #29
Removed
yarn.lockWas very old and out of date. Will ensure outdated lock file is not used when using
yarnas the installerThrow when a process in
ExecuteCommand.phpfailsRemoved some debug logs