@ibm-cloud/cd-tools 1.15.9 → 1.15.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -262,10 +262,7 @@ export async function importTerraform(token, apiKey, region, toolchainId, toolch
|
|
|
262
262
|
if (propValue.startsWith(START_INDICATOR) && propValue.endsWith(END_INDICATOR)) {
|
|
263
263
|
// skip substitution for jsonencode case, don't want to mangle it
|
|
264
264
|
} else {
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
// TODO: remove extra backslash in newline replacement once provider is updated
|
|
268
|
-
newValue = newValue.replace(/\\/g, '\\\\').replace(/\n/g, '\\\\n').replace(/\r/g, '\\\\r').replace(/"/g, '\\"');
|
|
265
|
+
newValue = newValue.replace(/\\/g, '\\\\').replace(/\n/g, '\\n').replace(/\r/g, '\\r').replace(/"/g, '\\"');
|
|
269
266
|
}
|
|
270
267
|
newTfFileObj['resource'][key][k]['value'] = newValue;
|
|
271
268
|
}
|
package/cmd/utils/terraform.js
CHANGED
|
@@ -360,8 +360,7 @@ async function setupTerraformFiles(config) {
|
|
|
360
360
|
if (thisValue.startsWith(START_INDICATOR) && thisValue.endsWith(END_INDICATOR)) {
|
|
361
361
|
// skip newline substitution for jsonencode case, don't want to mangle it
|
|
362
362
|
} else {
|
|
363
|
-
|
|
364
|
-
newTfFileObj['resource']['ibm_cd_tekton_pipeline_property'][k]['value'] = thisValue.replace(/\\/g, '\\\\').replace(/\n/g, '\\\\n').replace(/\r/g, '\\\\r').replace(/"/g, '\\"');
|
|
363
|
+
newTfFileObj['resource']['ibm_cd_tekton_pipeline_property'][k]['value'] = thisValue.replace(/\\/g, '\\\\').replace(/\n/g, '\\n').replace(/\r/g, '\\r').replace(/"/g, '\\"');
|
|
365
364
|
}
|
|
366
365
|
}
|
|
367
366
|
} catch (err) {
|
|
@@ -389,8 +388,7 @@ async function setupTerraformFiles(config) {
|
|
|
389
388
|
if (thisValue.startsWith(START_INDICATOR) && thisValue.endsWith(END_INDICATOR)) {
|
|
390
389
|
// skip newline substitution for jsonencode case, don't want to mangle it
|
|
391
390
|
} else {
|
|
392
|
-
|
|
393
|
-
newTfFileObj['resource']['ibm_cd_tekton_pipeline_trigger_property'][k]['value'] = thisValue.replace(/\\/g, '\\\\').replace(/\n/g, '\\\\n').replace(/\r/g, '\\\\r').replace(/"/g, '\\"');
|
|
391
|
+
newTfFileObj['resource']['ibm_cd_tekton_pipeline_trigger_property'][k]['value'] = thisValue.replace(/\\/g, '\\\\').replace(/\n/g, '\\n').replace(/\r/g, '\\r').replace(/"/g, '\\"');
|
|
394
392
|
}
|
|
395
393
|
}
|
|
396
394
|
} catch (err) {
|