maximodev-cli
Advanced tools
Comparing version 1.0.11 to 1.0.12
{ | ||
"name": "maximodev-cli", | ||
"version": "1.0.11", | ||
"version": "1.0.12", | ||
"description": "Maximo developer command line tools", | ||
@@ -5,0 +5,0 @@ "main": "src/maximodev-cli.js", |
@@ -21,5 +21,8 @@ //Find a way to inject it | ||
//Escape xml-validation | ||
//return xmlescape(codeScript); | ||
// NOTE: this gets auto-escaped in the final template | ||
codeScript = xmlescape(codeScript); | ||
// encode newlines in the script | ||
codeScript = codeScript.replace(/[\r\n]+/g, ' '); | ||
return codeScript; | ||
} |
@@ -11,14 +11,14 @@ const fs = require('fs'); | ||
scriptv_js.validate = function (codeScript) { | ||
var flags = 'gim'; | ||
var removeComments = /(\/\*.*?\*\/|\/\/[^\r\n]*$)/gmi; | ||
var strFilterRegEx = new RegExp(removeComments, flags); | ||
removeComments = '[' + removeComments + ']'; | ||
//Show pattern | ||
//log.info('strFilterRegEx: ' + strFilterRegEx); | ||
//Replace commands | ||
codeScript = codeScript.replace(strFilterRegEx, ''); | ||
//TODO Implement new validation ad-hoc | ||
//log.info("Validating JavaScript:" + codeScript); | ||
codeScript = codeScript.replace(/[\r\n]+/g, '\r\n'); | ||
// var flags = 'gim'; | ||
// var removeComments = /(\/\*.*?\*\/|\/\/[^\r\n]*$)/gmi; | ||
// var strFilterRegEx = new RegExp(removeComments, flags); | ||
// removeComments = '[' + removeComments + ']'; | ||
// //Show pattern | ||
// //log.info('strFilterRegEx: ' + strFilterRegEx); | ||
// //Replace commands | ||
// codeScript = codeScript.replace(strFilterRegEx, ''); | ||
// //TODO Implement new validation ad-hoc | ||
// //log.info("Validating JavaScript:" + codeScript); | ||
return codeScript; | ||
} |
@@ -10,15 +10,16 @@ var log = require('../logger'); | ||
scriptv_py.validate = function (codeScript) { | ||
codeScript = codeScript.replace(/[\r\n]+/g, '\r\n'); | ||
var flags = 'gim'; | ||
var removeComments = /(#\*.*?|#[^\r\n]*$)/g; | ||
var strFilterRegEx = new RegExp(removeComments, flags); | ||
// var flags = 'gim'; | ||
// var removeComments = /(#\*.*?|#[^\r\n]*$)/g; | ||
// var strFilterRegEx = new RegExp(removeComments, flags); | ||
removeComments = '[' + removeComments + ']'; | ||
//Show pattern | ||
//log.info('strFilterRegEx: ' + strFilterRegEx); | ||
//Replace commands | ||
codeScript = codeScript.replace(strFilterRegEx,''); | ||
//TODO Implement new validation ad-hoc | ||
//log.info("validate Python Script:" + codeScript); | ||
// removeComments = '[' + removeComments + ']'; | ||
// //Show pattern | ||
// //log.info('strFilterRegEx: ' + strFilterRegEx); | ||
// //Replace commands | ||
// codeScript = codeScript.replace(strFilterRegEx,''); | ||
// //TODO Implement new validation ad-hoc | ||
// //log.info("validate Python Script:" + codeScript); | ||
return codeScript; | ||
} |
@@ -1,1 +0,6 @@ | ||
//Script to merge into dbc.in | ||
//Script to merge into dbc.in | ||
//this is not a real script, and you will need update / create the contents according to your needs | ||
if (status == 'COMP') { | ||
mbo.setValue('ActStart', mbo.getDate('SchedStart')); | ||
mbo.setValue('ActFinish', mbo.getDate('SchedFinish')); | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
652573
5656