从TeamCity运行Bower?

5

我有一个使用Windows构建的团队城市,流程包括3个步骤。我想添加一个bower步骤,以安装项目中bower.json中的所有依赖项,而不是检查lib文件夹。

目前的步骤如下:

  1. NPM(安装,安装grunt-cli,安装grunt)
  2. Grunt
  3. karma

我对node或teamcity不太熟悉,并尝试执行以下操作。在(1)中添加“install bower”。在(1)之后添加一个新步骤,运行node.js并使用“bower --force-latest”,但遇到了各种错误。请问有人能逐步解释如何运行bower或是否应该运行?

1个回答

7
< p > 搞定了: < /p>
1) installed grunt and bower onto the server
2) updated the PATH environment variables to include bower
3) rebooted the build box
4) added a command line build step running bower from the correct project working directory: bower install -f

它起作用了!所有的bower软件包已安装。Karma单元测试现在可以正常工作,不会抱怨依赖关系!我现在可以从提交中删除lib文件夹...


网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接