mirror of
https://github.com/SAP/jenkins-library.git
synced 2024-12-14 11:03:09 +02:00
one shArgs array for all sh calls.
This commit is contained in:
parent
b21541c9f6
commit
ef8c4dafcf
@ -257,10 +257,17 @@ public class ChangeManagement implements Serializable {
|
|||||||
passwordVariable: 'password',
|
passwordVariable: 'password',
|
||||||
usernameVariable: 'username')]) {
|
usernameVariable: 'username')]) {
|
||||||
|
|
||||||
|
Map shArgs = [:]
|
||||||
|
|
||||||
|
if(returnStdout)
|
||||||
|
shArgs.put('returnStdout', true)
|
||||||
|
else
|
||||||
|
shArgs.put('returnStatus', true)
|
||||||
|
|
||||||
if(type == BackendType.RFC) {
|
if(type == BackendType.RFC) {
|
||||||
|
|
||||||
Map shArgs = [returnStatus: true,
|
shArgs.script = command
|
||||||
'script': command]
|
|
||||||
args = args.plus([
|
args = args.plus([
|
||||||
"--env ABAP_DEVELOPMENT_SERVER=${endpoint}",
|
"--env ABAP_DEVELOPMENT_SERVER=${endpoint}",
|
||||||
"--env ABAP_DEVELOPMENT_USER=${script.username}",
|
"--env ABAP_DEVELOPMENT_USER=${script.username}",
|
||||||
@ -286,13 +293,7 @@ public class ChangeManagement implements Serializable {
|
|||||||
command, args,
|
command, args,
|
||||||
clientOpts)
|
clientOpts)
|
||||||
|
|
||||||
Map shArgs = [:]
|
shArgs.script = cmScript
|
||||||
if(returnStdout)
|
|
||||||
shArgs.put('returnStdout', true)
|
|
||||||
else
|
|
||||||
shArgs.put('returnStatus', true)
|
|
||||||
|
|
||||||
shArgs.put('script', cmScript)
|
|
||||||
|
|
||||||
// user and password are masked by withCredentials
|
// user and password are masked by withCredentials
|
||||||
script.echo """[INFO] Executing command line: "${cmScript}"."""
|
script.echo """[INFO] Executing command line: "${cmScript}"."""
|
||||||
|
Loading…
Reference in New Issue
Block a user