Skip to content
This repository was archived by the owner on May 20, 2025. It is now read-only.
This repository was archived by the owner on May 20, 2025. It is now read-only.

Use the CodePush Management SDK inside electron #433

@wilomgfx

Description

@wilomgfx

I am just wondering if its possible to use the CodePush Management SDK within electron/node-webkit.

Im looking to build a GUI application to manage code-push enabled apps. I know i could use the cli, but as i saw the SDK, it made no sense to call the cli for each commands.

Unfortunately, when i import CodePush from 'code-push'; from my electron app( using webpack2) i get this error :

Uncaught TypeError: require is not a function
at Object../node_modules/formidable/lib/incoming_form.js (incoming_form.js:3)
at webpack_require (bootstrap e7cce0a…:657)
at fn (bootstrap e7cce0a…:85)
at Object../node_modules/formidable/lib/index.js (index.js:1)
at webpack_require (bootstrap e7cce0a…:657)
at fn (bootstrap e7cce0a…:85)
at Object../node_modules/superagent/lib/node/index.js (index.js:7)
at webpack_require (bootstrap e7cce0a…:657)
at fn (bootstrap e7cce0a…:85)
at Object../node_modules/code-push/script/management-sdk.js (management-sdk.js:6)

Which makes me think it is not usable with something other than node directly. Maybe im wrong, but i've looked into resolving the issue and could not find a solution! Thanks :)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions