forge
forge copied to clipboard
fix(plugin-local-electron): Make the plugin compatible on Windows, and can live with other plugins
- [x] I have read the contribution documentation for this project.
- [x] I agree to follow the code of conduct that this project follows, as appropriate.
- [x] The changes are appropriately documented (if applicable).
- [x] The changes have sufficient test coverage (if applicable).
- [x] The testsuite passes successfully on my local machine (if applicable).
Summarize your changes:
The plugin-local-electron currently cannot work with plugin-vite (or any other plugin) because it claims startLogic, which is unnecessary because it just merely set the ELECTRON_OVERRIDE_DIST_PATH env var.
This PR:
- Moved this logic to
initfunction instead ofstartLogic - Changed function
locateElectronExecutableto detect thisELECTRON_OVERRIDE_DIST_PATHenv var to make the project directly starts the binary in the wanted path. (Because on Windows this env variable makes no effect and still launch the binary undernode_modules...)
@caoxiemeihao Can I bother you review this?
@VerteDinde Can you review this PR?😘
@reitowo please can you resolve conflicts?
https://github.com/electron/forge/pull/3720 should resolve the issues with conflicting startLogic
@brianlyn thanks for pointing that out!