Skip to content

Commit

Permalink
chore: use console.log where appropriate. Move log.js
Browse files Browse the repository at this point in the history
  • Loading branch information
ms14981 authored and ColinEberhardt committed Feb 2, 2023
1 parent 77a813e commit b82121a
Show file tree
Hide file tree
Showing 7 changed files with 6 additions and 7 deletions.
2 changes: 1 addition & 1 deletion CICD/compareTestResults.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const fs = require("fs");

const log = require("../src/log.js");
const log = require("../src//common/log");

log.setLogLevel(log.logLevels.verbose);

Expand Down
2 changes: 1 addition & 1 deletion CICD/updateWebpage.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const fs = require("fs");

const log = require("../src/log.js");
const log = require("../src/common/log");

// This regex extracts the generator table from README.md.
const tableRegex =
Expand Down
2 changes: 1 addition & 1 deletion src/common/generatorResolver.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ const os = require("os");
const shell = require("shelljs");
const URL = require("url").URL;

const log = require("../log");
const log = require("./log");

let npmPackage;
let temporaryFolder;
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/forge/generate.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const { parse } = require("yaml");

const generatorResolver = require("../common/generatorResolver");
const helpers = require("../helpers");
const log = require("../log");
const log = require("../common/log");
const transformers = require("../transformers");
const SwaggerParser = require("@apidevtools/swagger-parser");
const converter = require("swagger2openapi");
Expand Down
3 changes: 1 addition & 2 deletions src/generatorOptions/index.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
const log = require("../log");
const { generatorOptions } = require("./generatorOptions");

const generatorOptionsCommand = function (program) {
Expand All @@ -12,7 +11,7 @@ const generatorOptionsCommand = function (program) {
"Git URL, file path or npm package of a language-specific generator"
)
.action(async (generator) => {
log.standard(await generatorOptions(generator));
console.log(await generatorOptions(generator));
});
};

Expand Down
2 changes: 1 addition & 1 deletion src/testGenerators/testGenerators.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
const path = require("path");
const shell = require("shelljs");

const log = require("../log");
const log = require("../common/log");

function isJson(str) {
try {
Expand Down

0 comments on commit b82121a

Please sign in to comment.