Skip to content

[Feature] Automatically unplug dependencies with binary executables #663

Closed
@merceyz

Description

@merceyz
  • I'd be willing to implement this feature
  • This feature can already be implemented through a plugin

Describe the user story

When a user is trying to build an electron project using electron-builder the build fails because Windows can't execute an exe file within a zip archive

Describe the solution you'd like

That Yarn would detect that a dependency has executeable files and automatically unplug said dependency

Describe the drawbacks of your solution

Yarn would have to do more work at install time

Describe alternatives you've considered

  • Opening a PR upstream to add a empty postinstall script just to have yarn unplug it automatically, this would only solve the problem for this one dependency.
  • Running yarn unplug on the offending package(s), creates another hurdle for PnP adoptation

Additional context
Where electron-builder spawns the package
https://github.com/electron-userland/electron-builder/blob/e1a7ec9f3f7dde69b99dc8c809aac688803ee9a9/packages/builder-util/src/util.ts#L337-L369
The package that needs to be unplugged:
https://github.com/Loller79/app-builder-bin

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions