javascript - electron打包
迷茫
迷茫 2017-04-11 12:49:34
[JavaScript讨论组]

自己写了一个demo想打包可是总是失败于是从git上拉了项目什么都不动进行打包,可是还是报npm的错误以下是json文件 并且附上报错信息,求解决

{
"name": "sound_machine",
"version": "0.1.0",
"main": "./main.js",
"scripts": {

"start": "electron .",
"package": "electron-packager ./ SoundMachine --mac --out ~/Desktop/SoundMachine --version 0.30.2 --overwrite --icon=./app/img/app-icon.icns"

},
"devDependencies": {

"electron-packager": "^5.0.1",
"electron-prebuilt": "^0.30.3"

},
"dependencies": {

"nconf": "^0.7.2"

}
}

npm ERR! Darwin 16.1.0
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "run-script" "package"
npm ERR! node v6.4.0
npm ERR! npm v4.2.0
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! sound_machine@0.1.0 package: electron-packager ./ SoundMachine --mac --out ~/Desktop/SoundMachine --version 0.30.2 --overwrite --icon=./app/img/app-icon.icns
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the sound_machine@0.1.0 package script 'electron-packager ./ SoundMachine --mac --out ~/Desktop/SoundMachine --version 0.30.2 --overwrite --icon=./app/img/app-icon.icns'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the sound_machine package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! electron-packager ./ SoundMachine --mac --out ~/Desktop/SoundMachine --version 0.30.2 --overwrite --icon=./app/img/app-icon.icns
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs sound_machine
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls sound_machine
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR! /Users/dongly/.npm/_logs/2017-02-15T07_03_52_813Z-debug.log
localhost:sound-machine-electron-guide dongly$

迷茫
迷茫

业精于勤,荒于嬉;行成于思,毁于随。

全部回复(1)
高洛峰

问题已经解决 Mac 下 打包要用到wine

热门教程
更多>
最新下载
更多>
网站特效
网站源码
网站素材
前端模板
关于我们 免责申明 举报中心 意见反馈 讲师合作 广告合作 最新更新 English
php中文网:公益在线php培训,帮助PHP学习者快速成长!
关注服务号 技术交流群
PHP中文网订阅号
每天精选资源文章推送
PHP中文网APP
随时随地碎片化学习

Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号