From f49e442dc6e54aff8cd2bef14f7de0bf3e08c74c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rn=20Berkefeld?= Date: Tue, 17 Sep 2024 16:51:06 +0200 Subject: [PATCH 1/3] #1717: improve validation rule typing --- @types/lib/util/validations.d.ts | 2 ++ @types/lib/util/validations.d.ts.map | 2 +- @types/types/mcdev.d.d.ts | 17 +++++++++++++++++ @types/types/mcdev.d.d.ts.map | 2 +- lib/util/validations.js | 11 +++++++++-- types/mcdev.d.js | 13 +++++++++++++ 6 files changed, 43 insertions(+), 4 deletions(-) diff --git a/@types/lib/util/validations.d.ts b/@types/lib/util/validations.d.ts index cc946582f..ec8173ad6 100644 --- a/@types/lib/util/validations.d.ts +++ b/@types/lib/util/validations.d.ts @@ -6,4 +6,6 @@ * @param {string} targetDir folder in which the MetadataItem is deployed from (deploy/cred/bu) */ export default function validation(definition: any, item: any, targetDir: string): Promise; +export type validationRuleList = import("../../types/mcdev.d.js").validationRuleList; +export type validationRuleTest = import("../../types/mcdev.d.js").validationRuleTest; //# sourceMappingURL=validations.d.ts.map \ No newline at end of file diff --git a/@types/lib/util/validations.d.ts.map b/@types/lib/util/validations.d.ts.map index a338f8046..5325c65b4 100644 --- a/@types/lib/util/validations.d.ts.map +++ b/@types/lib/util/validations.d.ts.map @@ -1 +1 @@ -{"version":3,"file":"validations.d.ts","sourceRoot":"","sources":["../../../lib/util/validations.js"],"names":[],"mappings":"AAWA;;;;;;GAMG;AACH,+CALW,GAAG,QACH,GAAG,aAEH,MAAM,GADJ,OAAO,CAAE,GAAG,CAAC,CAkDzB"} \ No newline at end of file +{"version":3,"file":"validations.d.ts","sourceRoot":"","sources":["../../../lib/util/validations.js"],"names":[],"mappings":"AAiBA;;;;;;GAMG;AACH,+CALW,GAAG,QACH,GAAG,aAEH,MAAM,GADJ,OAAO,CAAE,GAAG,CAAC,CAmDzB;iCAnEY,OAAO,wBAAwB,EAAE,kBAAkB;iCACnD,OAAO,wBAAwB,EAAE,kBAAkB"} \ No newline at end of file diff --git a/@types/types/mcdev.d.d.ts b/@types/types/mcdev.d.d.ts index b4a024325..93f605578 100644 --- a/@types/types/mcdev.d.d.ts +++ b/@types/types/mcdev.d.d.ts @@ -1705,4 +1705,21 @@ export type FieldCondition = { */ text: string; }; +export type validationRuleTest = () => boolean; +export type validationRule = { + /** + * error message to display in case of a failed test + */ + failedMsg: string; + /** + * test to run + */ + passed: validationRuleTest; +}; +/** + * key=rule name + */ +export type validationRuleList = { + [x: string]: validationRule; +}; //# sourceMappingURL=mcdev.d.d.ts.map \ No newline at end of file diff --git a/@types/types/mcdev.d.d.ts.map b/@types/types/mcdev.d.d.ts.map index cc77ccdb4..d88225dab 100644 --- a/@types/types/mcdev.d.d.ts.map +++ b/@types/types/mcdev.d.d.ts.map @@ -1 +1 @@ -{"version":3,"file":"mcdev.d.d.ts","sourceRoot":"","sources":["../../types/mcdev.d.js"],"names":[],"mappings":";;;;;;eAEc,MAAM;;;;mBACN,MAAM;;;;aACN,MAAM;;;;UACN,MAAM;;;;UACN,MAAM;;;;mBACN,MAAM;;;;iBACN,MAAM;;0BAIP;QAAQ,MAAM,GAAE,MAAM;CAAC;qCACvB,OAAO,GAAC,eAAe,GAAC,aAAa,GAAC,aAAa,GAAC,aAAa,GAAC,YAAY,GAAC,gBAAgB,GAAC,aAAa,GAAC,eAAe,GAAC,aAAa,GAAC,gBAAgB,GAAC,gBAAgB,GAAC,gBAAgB,GAAC,aAAa,GAAC,gBAAgB,GAAC,cAAc,GAAC,YAAY,GAAC,UAAU,GAAC,aAAa,GAAC,eAAe,GAAC,oBAAoB,GAAC,uBAAuB,GAAC,aAAa,GAAC,iBAAiB,GAAC,WAAW,GAAC,iBAAiB,GAAC,OAAO,GAAC,WAAW,GAAC,OAAO,GAAC,cAAc,GAAC,cAAc,GAAC,QAAQ,GAAC,QAAQ,GAAC,YAAY,GAAC,SAAS,GAAC,MAAM,GAAC,YAAY,GAAC,eAAe,GAAC,eAAe,GAAC,OA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V,MAAM;;;;gBAEjB;QAA8B,kBAAkB,EAArC,MAAM;QACa,gBAAgB,EAAnC,MAAM;QACc,aAAa,EAAjC,OAAO;QACY,mBAAmB,EAAtC,MAAM;QACc,SAAS,GAA7B,MAAM;KACjB;;;;yBACA;QAAuC,MAAM,EAC7C;YAA8C,UAAU,EAA7C,MAAM;YAC6B,KAAK,EAAxC,MAAM;YAC8B,kBAAkB,GAAtD,MAAM;SACjB;KAAA;;;;gCAAW,MAAM;;;;gCACN,MAAM;;;;sBACN,MAAM,EAAE;;;;+BACR,UAAU,GAAC,UAAU,GAAC,kBAAkB;;;;uBACxC,gBAAgB,GAAC,SAAS;;;;mBAC1B,MAAM;;;;iBACN,MAAM;;;;cACN,MAAM;;;;qBACN,MAAM;;;;;;;;;cAKN,MAAM;;;;mBACN,OAAO;;;;qBACP,MAAM;;;;sBACN,MAAM;;;;yBACN,MAAM;;;;YACN,MAAM,EAAE;;;;;;;;;aAIR,KAAK,GAAC,IAAI;;;;gBACV,CAAC,UAAU,GAAG,cAAc,CAAC,EAAE;;;;;;;;;aAI/B,MAAM;;;;cACN,UAAU,GAAC,QAAQ,GAAC,KAAK,GAAC,UAAU,GAAC,UAAU,GAAC,SAAS,GAAC,MAAM,GAAC,UAAU,GAAC,OAAO;;;;eACnF,MAAM;;;;cACN,MAAM;;;;QACN,MAAM;;;;mBACN,OAAO;;;;UACP,MAAM;;;;cACN,QAAQ,GAAC,QAAQ,GAAC,QAAQ;;;;YAC1B,MAAM;;;;eACN,MAAM;;;;yBACN,MAAM;;;;wBACN,MAAM;;;;sBACN,MAAM;;;;WACN,MAAM;;;;UACN,MAAM;;uCAKP,OAAO;;;;;eAIN,MAAM;;;;YACN,kBAAkB;;;;;iCAGnB;QAAQ,MAAM,GAAE,cAAc;CAAC"} \ No newline at end of file diff --git a/lib/util/validations.js b/lib/util/validations.js index 80c412b40..c47dc0eee 100644 --- a/lib/util/validations.js +++ b/lib/util/validations.js @@ -2,6 +2,12 @@ import path from 'node:path'; import { Util } from './util.js'; +/** + * @typedef {import('../../types/mcdev.d.js').validationRuleList} validationRuleList + * @typedef {import('../../types/mcdev.d.js').validationRuleTest} validationRuleTest + */ + +/** @type {validationRuleList} */ let customRules = {}; let customRuleImport; try { @@ -28,11 +34,12 @@ export default async function validation(definition, item, targetDir) { 'Could not load custom validation rules from .mcdev-validations.js: ' + ex.message ); } + /** @type {validationRuleList} */ const defaultRules = { noGuidKeys: { failedMsg: 'Please update the key to a readable value. Currently still in GUID format.', /** - * @returns {boolean} true=test passed + * @type {validationRuleTest} */ passed: function () { const key = item[definition.keyField]; @@ -48,7 +55,7 @@ export default async function validation(definition, item, targetDir) { noRootFolder: { failedMsg: 'Root folder not allowed. Current folder: ' + item.r__folder_Path, /** - * @returns {boolean} true=test passed + * @type {validationRuleTest} */ passed: function () { /** @type {string} */ diff --git a/types/mcdev.d.js b/types/mcdev.d.js index ffa0d7912..c1418e28e 100644 --- a/types/mcdev.d.js +++ b/types/mcdev.d.js @@ -625,5 +625,18 @@ complex * @property {number} scale ? * @property {string} text seems to be equal to name-attribute?; "Email" */ +/** + * + * @callback validationRuleTest + * @returns {boolean} true = test passed; false = test failed + */ +/** + * @typedef {object} validationRule + * @property {string} failedMsg error message to display in case of a failed test + * @property {validationRuleTest} passed test to run + */ +/** + * @typedef {Object.} validationRuleList key=rule name + */ export default {}; From 94d188ae384cb49bd503df171fb2f6f1359922d1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rn=20Berkefeld?= Date: Tue, 17 Sep 2024 16:53:46 +0200 Subject: [PATCH 2/3] #1717: add --skipValidation to retrieve --- lib/cli.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lib/cli.js b/lib/cli.js index ececbc875..01cd78cd2 100644 --- a/lib/cli.js +++ b/lib/cli.js @@ -50,6 +50,12 @@ yargs(hideBin(process.argv)) group: 'Options for retrieve:', describe: 'filter metadata components (can include % as wildcard or _ for a single character)', + }) + .option('skipValidation', { + alias: 'sv', + group: 'Options for retrieve:', + describe: + 'allows reducing validation rules from error to warn to handle edge cases', }), (argv) => { Mcdev.setOptions(argv); From bd863a37b96f363c78f229b684c22e067edc2126 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rn=20Berkefeld?= Date: Tue, 17 Sep 2024 16:55:09 +0200 Subject: [PATCH 3/3] #1717: fix deploy option description --- lib/cli.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/cli.js b/lib/cli.js index 01cd78cd2..9001e3904 100644 --- a/lib/cli.js +++ b/lib/cli.js @@ -600,7 +600,7 @@ yargs(hideBin(process.argv)) }) .option('skipValidation', { alias: 'sv', - group: 'Options for deploy:', + group: 'Options for buildDefinitionBulk:', describe: 'allows reducing validation rules from error to warn to handle edge cases', }),