We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8d55086 commit 30d9cd0Copy full SHA for 30d9cd0
src/org/devops/build.groovy
@@ -2,14 +2,19 @@ package org.devops
2
3
// Node构建命令
4
5
-def Build(){
6
- buildHome = tool "NPM"
7
-
8
- // println("${buildHome}")
9
10
- sh """
11
- ${buildHome}/bin/npm install --registry=https://registry.npm.taobao.org
12
- ${buildHome}/bin/npm run build:stage
+def Build(build){
+ if ("${build}" == true) {
+ buildHome = tool "NPM"
+ sh """
+ ${buildHome}/bin/npm install --registry=https://registry.npm.taobao.org
+ ${buildHome}/bin/npm run build:stage
13
"""
+} else {
+ println("非编译项目")
14
+}
15
+
16
17
18
19
20
}
0 commit comments