mirror of
https://github.com/SAP/jenkins-library.git
synced 2025-03-03 15:02:35 +02:00
fix code climate issues
This commit is contained in:
parent
9305a52d0f
commit
2aa9f5215a
@ -236,18 +236,19 @@ public class ChangeManagement implements Serializable {
|
||||
}
|
||||
}
|
||||
|
||||
def executeWithCredentials(BackendType type,
|
||||
String dockerImage,
|
||||
List dockerOptions,
|
||||
String endpoint,
|
||||
String credentialsId,
|
||||
String command,
|
||||
def args,
|
||||
boolean returnStdout = false,
|
||||
String clientOpts = '') {
|
||||
def executeWithCredentials(
|
||||
BackendType type,
|
||||
String dockerImage,
|
||||
List dockerOptions,
|
||||
String endpoint,
|
||||
String credentialsId,
|
||||
String command,
|
||||
def args,
|
||||
boolean returnStdout = false,
|
||||
String clientOpts = '') {
|
||||
|
||||
def script = this.script
|
||||
script.withCredentials([script.usernamePassword(
|
||||
def script = this.script
|
||||
script.withCredentials([script.usernamePassword(
|
||||
credentialsId: credentialsId,
|
||||
passwordVariable: 'password',
|
||||
usernameVariable: 'username')]) {
|
||||
@ -280,9 +281,10 @@ public class ChangeManagement implements Serializable {
|
||||
// user and password are masked by withCredentials
|
||||
script.echo """[INFO] Executing command line: "${shArgs.script}"."""
|
||||
|
||||
script.dockerExecute(script: script,
|
||||
dockerImage: dockerImage,
|
||||
dockerEnvVars: args ) {
|
||||
script.dockerExecute(
|
||||
script: script,
|
||||
dockerImage: dockerImage,
|
||||
dockerEnvVars: args ) {
|
||||
|
||||
result = script.sh(shArgs)
|
||||
|
||||
|
@ -107,14 +107,14 @@ void call(parameters = [:]) {
|
||||
configuration.changeManagement.credentialsId,
|
||||
configuration.changeManagement.clientOpts)
|
||||
} else if (backendType == BackendType.RFC) {
|
||||
transportRequestId = cm.createTransportRequestRFC(
|
||||
configuration.changeManagement.rfc.dockerImage,
|
||||
configuration.changeManagement.rfc.dockerOptions ?: [],
|
||||
configuration.changeManagement.endpoint,
|
||||
onfiguration.changeManagement.rfc.developmentInstance,
|
||||
configuration.changeManagement.rfc.developmenClient,
|
||||
configuration.changeManagement.credentialsId,
|
||||
configuration.description)
|
||||
transportRequestId = cm.createTransportRequestRFC(
|
||||
configuration.changeManagement.rfc.dockerImage,
|
||||
configuration.changeManagement.rfc.dockerOptions ?: [],
|
||||
configuration.changeManagement.endpoint,
|
||||
onfiguration.changeManagement.rfc.developmentInstance,
|
||||
configuration.changeManagement.rfc.developmenClient,
|
||||
configuration.changeManagement.credentialsId,
|
||||
configuration.description)
|
||||
} else {
|
||||
throw new IllegalArgumentException("Invalid backend type: '${backendType}'.")
|
||||
}
|
||||
|
@ -21,10 +21,10 @@ import static com.sap.piper.cm.StepHelpers.getBackendTypeAndLogInfoIfCMIntegrati
|
||||
]
|
||||
|
||||
@Field Set STEP_CONFIG_KEYS = GENERAL_CONFIG_KEYS.plus([
|
||||
'applicationName', // RFC
|
||||
'applicationId', // SOLMAN
|
||||
'applicationDescription',
|
||||
'abapPackage',
|
||||
'applicationName', // RFC
|
||||
'applicationId', // SOLMAN
|
||||
'applicationDescription',
|
||||
'abapPackage',
|
||||
])
|
||||
|
||||
@Field Set PARAMETER_KEYS = STEP_CONFIG_KEYS.plus([
|
||||
|
Loading…
x
Reference in New Issue
Block a user