首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >构建1.0测试版的问题

构建1.0测试版的问题
EN

Stack Overflow用户
提问于 2016-05-10 12:13:32
回答 2查看 54关注 0票数 0

我在尝试运行npm start时遇到以下错误。看起来在package.json中有一个“构建”脚本。npm build不输出任何内容。有什么想法吗?

代码语言:javascript
复制
λ npm start                                                                                                    

> quill@1.0.0-beta.1 start C:\repos\github\quill                                                               
> npm run build; foreman start -f _develop/procfile                                                            

npm WARN using --force I sure hope you know what you are doing.                                                
npm ERR! Windows_NT 10.0.10586                                                                                 
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli
.js" "run" "build;" "foreman" "start" "-f" "_develop/procfile"                                                 
npm ERR! node v4.2.1                                                                                           
npm ERR! npm  v2.14.7                                                                                          

npm ERR! missing script: build;                                                                                
npm ERR!                                                                                                       
npm ERR! If you need help, you may report this error at:                                                       
npm ERR!     <https://github.com/npm/npm/issues>                                                               

npm ERR! Please include the following file with any support request:                                           
npm ERR!     C:\repos\github\quill\npm-debug.log                                                               

npm ERR! Windows_NT 10.0.10586                                                                                 
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli
.js" "start"                                                                                                   
npm ERR! node v4.2.1                                                                                           
npm ERR! npm  v2.14.7                                                                                          
npm ERR! code ELIFECYCLE                                                                                       
npm ERR! quill@1.0.0-beta.1 start: `npm run build; foreman start -f _develop/procfile`                         
npm ERR! Exit status 1                                                                                         
npm ERR!                                                                                                       
npm ERR! Failed at the quill@1.0.0-beta.1 start script 'npm run build; foreman start -f _develop/procfile'.    
npm ERR! This is most likely a problem with the quill package,                                                 
npm ERR! not with npm itself.                                                                                  
npm ERR! Tell the author that this fails on your system:                                                       
npm ERR!     npm run build; foreman start -f _develop/procfile                                                 
npm ERR! You can get their info via:                                                                           
npm ERR!     npm owner ls quill                                                                                
npm ERR! There is likely additional logging output above.                                                      

npm ERR! Please include the following file with any support request:                                           
npm ERR!     C:\repos\github\quill\npm-debug.log                                                               
EN

回答 2

Stack Overflow用户

发布于 2016-05-10 12:37:08

npm scripts是与npm run一起运行的,因此您需要调用npm run build。为什么npm build什么都不做是npm的怪癖:npm build doesn't run the script named "build" in package.json

票数 0
EN

Stack Overflow用户

发布于 2016-07-22 17:52:28

将开始脚本更改为以下内容:

代码语言:javascript
复制
"start": "npm run build \"foreman start -f _develop/procfile\"",

有几个字符被转义

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/37129147

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档