简体   繁体   English

Sopaui git jenkins 集成

[英]Sopaui git jenkins integration

Hi I am using below code in build step in jenkin您好,我在 jenkin 的构建步骤中使用以下代码

#!/bin/bash
pwd
cd ./eclipse-workspace/SoapUiTest
pwd
javac -classpath "lib/* -d ./bin ./src/defaultPackage/*.java" 
java -cp "bin;lib/* org.testng.TestNG testng.xml"

while running job i am getting below error运行作业时出现以下错误

javac: no source files Usage: javac use -help for a list of possible options Usage: java [-options] class [args...] (to execute a class) or java [-options] -jar jarfile [args...] (to execute a jar file) where options include: -d32 use a 32-bit data model if available -d64 use a 64-bit data model if available -server to select the "server" VM -zero to select the "zero" VM -dcevm to select the "dcevm" VM The default VM is server, because you are running on a server-class machine. javac:没有源文件用法:javac使用-help获取可能选项列表用法:java [-options] class [args ...](执行一个类)或java [-options] -jar jarfile [args .. .](执行 jar 文件)其中选项包括:-d32 使用 32 位数据 model(如果可用)-d64 使用 64 位数据 model(如果可用)-server 到 select“服务器”VM -零到 88127421“008888零”VM -dcevm 到 select “dcevm”VM 默认 VM 是服务器,因为您在服务器级机器上运行。 -cp <class search path of directories and zip/jar files> -classpath <class search path of directories and zip/jar files> A: separated list of directories, JAR archives, and ZIP archives to search for class files. -cp <目录和zip/jar文件的类搜索路径> -classpath <目录和zip/jar文件的类搜索路径> A:分离目录列表,JAR档案,ZIP档案搜索class文件。

An obvious error is the mixure of flags in flag values in javac command:一个明显的错误是在 javac 命令中标志值中标志的混合:

#!/bin/bash
pwd
cd ./eclipse-workspace/SoapUiTest
pwd
javac -classpath "lib/*" -d "./bin" "./src/defaultPackage/*.java"  
java -cp "bin;lib/* org.testng.TestNG testng.xml"

javac command explanation: you specify where to find additional class binaries that the compilation depends on, where to output the compiled files and finally where to read the sources from. javac命令说明:您指定在哪里可以找到编译所依赖的其他 class 二进制文件,在哪里可以找到编译后的文件 output 最后从哪里读取源代码。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM