Skip to content

Commit

Permalink
ci: remove nodejs v12 exclusion logic from run custom checks
Browse files Browse the repository at this point in the history
Fixes hyperledger#1961

Signed-off-by: Youngone Lee <youngone.lee@accenture.com>
  • Loading branch information
Leeyoungone committed Apr 12, 2022
1 parent b363b18 commit 489e56d
Show file tree
Hide file tree
Showing 3 changed files with 1,075 additions and 1,013 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@
"tape-promise": "4.0.0",
"ts-jest": "27.0.3",
"ts-loader": "9.2.5",
"ts-node": "10.2.0",
"ts-node": "10.7.0",
"typescript": "4.3.5",
"webpack": "5.50.0",
"webpack-bundle-analyzer": "4.4.2",
Expand Down
10 changes: 1 addition & 9 deletions tools/custom-checks/run-custom-checks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,19 +6,11 @@ import { checkSiblingDepVersionConsistency } from "./check-sibling-dep-version-c
export async function runCustomChecks(
argv: string[],
env: NodeJS.ProcessEnv,
version: string,
): Promise<void> {
const TAG = "[tools/custom-checks/run-custom-checks.ts]";
let overallSuccess = true;
let overallErrors: string[] = [];

const [majorVersion] = version.split(".");
const nodeV12OrOlder = parseInt(majorVersion) <= 12;
if (nodeV12OrOlder) {
console.log(`${TAG} Checks skipped due to old NodeJS (v${version}) OK.`);
return;
}

{
const [success, errors] = await checkOpenApiJsonSpecs({ argv, env });
overallErrors = overallErrors.concat(errors);
Expand Down Expand Up @@ -49,5 +41,5 @@ export async function runCustomChecks(
}

if (esMain(import.meta)) {
runCustomChecks(process.argv, process.env, process.versions.node);
runCustomChecks(process.argv, process.env);
}

0 comments on commit 489e56d

Please sign in to comment.