sh: electron-builder: command not found
See original GitHub issue- Version: “electron-builder”: “^22.9.1”
- Electron Version: “electron”: “^10.1.5”,
- Electron Type (current, beta, nightly):
- Target:
Problem Description:
When i executenpm run pack
"build": "react-scripts build",
"dev": "concurrently \"wait-on http://localhost:3000 && electron .\" \"cross-env BROWSER=none npm start\"",
"pack": "electron-builder --dir",
"dist": "electron-builder",
"prepack": "npm run build"
He has the following error:
Issue Analytics
- State:
- Created 3 years ago
- Reactions:1
- Comments:11
Top Results From Across the Web
electron with react error bin sh build command not found
a temporary solution that i found is removing node modules files and run npm install rm -rf node_modules npm install.
Read more >Multi Platform Build - electron-builder
Build performed in parallel, so, it is highly recommended to not use npm task per platform (e.g. npm run dist:mac && npm run...
Read more >Advanced Installation Instructions
The above command will run the current working directory with Electron. Note that any dependencies in your app will not be installed.
Read more >sh electron-builder command not found
sh electron -builder command not found技术、学习、经验文章掘金开发者社区搜索结果。掘金是一个帮助开发者成长的社区,sh electron-builder command not found技术 ...
Read more >Npm install command failing with message "could not find ...
And the node_modules folder is not created. My computer setup: Windows 10 - Version 21H1 build 19043.1165 NodeJS / NPM - v16.6.1 /...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
At first try to install globally
And try again. If it doesn’t work then use
npx
in package.json.We’re also getting this error (
Command "electron-builder" not found
) when trying to run electron-builder from within apackage.json
script ("electron:win-build": "yarn build:prod && electron-builder build --win --ia32"
). Installing electron-builder globally in our case is NOT an acceptable solution (using CI infrastrukture). In particular, the electron-builder docs recommends installing the package locally (using yarn, see https://www.electron.build/#installation), providing the “runner” in thenode_modules/.bin
directory, which is searched for by yarn (and npm?) automatically. In my case, this problem occured on a win agent (with yarn v1.22.5) and after upgrading electron-builder from v22.8.1 -> v22.9.1, which caused theelectron-builder
runner missing in thenode_modules/.bin
directory after a cleanyarn install
(whereby I cannot exclude that the runner existing until then was an artifact of a previous update/install). Any help on this is very much appreciated.