electron-node-red
electron-node-red copied to clipboard
Generating an executable for my Electron Node-Red Application
Hello,
My goal is to generate an executable for my Electron Node-red Application, I am able to run the application locally using "npm install && npm start" only, please find below the steps that I used :
# Clone this repository
git clone https://github.com/natcl/electron-node-red.git # Go into the repository cd electron-node-red
#merged my flows and package file
./merger.js {used my path to my Node-RED project directory}
**then I tried to run it locally with success with commands yarn:
yarn yarn start In order to build an executable I used electron packager that I installed:
electron-packager . Node-RED --icon=nodered.icns --platform=linux --arch=x64 --out=build --overwrite Packaging app for platform linux x64 using electron v10.1.7 Wrote new app to build/Node-RED-linux-x64
yarn && yarn dist -l #failed error: ⨯ /home/engr/electron-node-red/node_modules/app-builder-bin/linux/x64/app-builder exited with code ERR_ELECTRON_BUILDER_CANNOT_EXECUTE stackTrace= AND error Command failed with exit code 1. info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command
I was hoping if you can please help me on this.
Thanks in advance !
if you are already on linux then maybe just try yarn dist as it will default to the local type.
Apart from that I'm afraid you will need to work out why electron builder isn't running (I use electron builder not electron packager so they may be conflicting or maybe it's not installed)
I finally got it work, I was missing rpm so I installed it "sudo apt-get install rpm" and then ran the command "yarn && yarn dist".
Thanks!
I have gotten an error while launching my electron node-red application, this is the error in screenshot:

Thanks again!
looks like the serialport hasn't compiled it's bindings correctly for electron on ubuntu. I'm afraid you will have to google for that.