我有以下代码在Jenkins的执行shell中。我的需求是在每一行中显示servername
参数以在控制台输出中显示。我使用了echo并获取了服务器名称,它们正在控制台中显示。
Code:
echo ${Server} PS_EXE="/cygdrive/powershell.exe"
echo ${Server} "wget user=$User pwd= $pwd http://artifactory/dev-package.zip"
echo ${Server} "sleep 20s"
所有行都包含回显服务器以显示服务器名称。
Output:
+echo SD998.domain.com PS_EXE="/cygdrive/powershell.exe"
SD998.domain.com PS_EXE="/cygdrive/powershell.exe"
+echo SD999.domain.com "wget user=$User pwd= $pwd http://artifactory/dev-package.zip"
SD999.domain.com "wget user=$User pwd= $pwd http://artifactory/dev-package.zip"
echo语句会在控制台输出中显示,然后才会显示输出结果。我需要从控制台输出中删除与echo相关的语句。请帮助我实现这一目标。