首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
MCP广场
社区首页 >问答首页 >如何使用Angular 11/12运行ngcc

如何使用Angular 11/12运行ngcc
EN

Stack Overflow用户
提问于 2021-11-09 20:29:40
回答 1查看 892关注 0票数 1

所以我们有一个monorepo,它有两个使用Angular的不同项目。我们也有一个构建管道来自动化集成过程。我遇到的问题是ngcc不支持并行执行。我想在并行进程开始之前手动运行ngcc命令,但我不知道如何执行?

该项目使用的是Angular 11,而且我已经在全球安装了@angular/cli@12.2.1,所以我希望ngcc成为那里的工具的一部分,但到目前为止还没有运气。我简单地得到了这个错误:-bash: ngcc: command not found

如果有人想知道,这就是我在尝试并行运行ng build时得到的错误:

代码语言:javascript
运行
复制
ERROR in ngcc is already running at process with id 2113.
If you are running multiple builds in parallel then you might try pre-processing your node_modules via the command line ngcc tool before starting the builds.
(If you are sure no ngcc process is running then you should delete the lock-file at /Users/runner/work/1/s/frontend/apps/MY_APP/node_modules/@angular/compiler-cli/ngcc/__ngcc_lock_file__.)
EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2021-11-09 20:52:57

你能试试吗:npx ngcc -s path

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

https://stackoverflow.com/questions/69904686

复制
相关文章

相似问题

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