Skip to content
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

Better node module support #59

Closed
malept opened this issue Feb 25, 2020 · 2 comments
Closed

Better node module support #59

malept opened this issue Feb 25, 2020 · 2 comments

Comments

@malept
Copy link

malept commented Feb 25, 2020

Is your feature request related to a problem? Please describe.

👋 I'm one of the developers for Electron Forge, and I'd like to create a first-class Electron Forge plugin that would hook into the workflow right after an application is packaged (but before installers are generated). Currently, the main script for the module is the same as the bin, so when you require('@doyensec/electronegativity'), you'll just run the CLI without any arguments. This is sub-optimal for Electron Forge, as we'd have to shell out in order to configure it in any way.

Describe the solution you'd like

Move the bin script to a different file than src/index.ts, and export a Node API-friendly function instead.

If this sounds reasonable, I'd be happy to create a pull request for this.

@ikkisoft
Copy link
Contributor

That's a great idea, and we would be welcome to support that change since it will bring security to many more Electron apps!

baltpeter added a commit to baltpeter/electronegativity that referenced this issue May 7, 2020
phosphore added a commit that referenced this issue May 8, 2020
Fixes #59: Allow running electronegativity programmatically
@malept
Copy link
Author

malept commented Aug 11, 2020

FWIW, this helped a lot, I now have a PR for what I described: electron/forge#1900

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants