diff --git a/lib/cli/commands/base.js b/lib/cli/commands/base.js index 555bf2555..40b1fd833 100644 --- a/lib/cli/commands/base.js +++ b/lib/cli/commands/base.js @@ -47,32 +47,12 @@ cli.usage("Usage: ui5 [options]") console.log(""); console.log(chalk.underline("Stack Trace:")); console.log(err.stack); - - // Try to guess responsible module from stack trace file paths - // This should work for the following paths: - // - @ui5/cli (npm consumption) - // - ui5-cli (local repository consumption) - // - lib/cli (local consumption without repository name in path, i.e. Azure CI) - const moduleRegExp = /@?(?:ui5|lib).(?:logger|fs|builder|server|project|cli)/ig; - - // Only check the lowest stack entry - const rootStackEntry = err.stack.split("\n")[1]; - const match = rootStackEntry.match(moduleRegExp); - if (match) { - // Use the last match of the line because of cases like this: - // node_modules/@ui5/cli/node_modules/@ui5/builder/lib/ => should match the builder - let moduleNameGuess = match[match.length - 1]; - - // Normalize match - moduleNameGuess = moduleNameGuess.replace(/.*(?:ui5|lib).(.*)/i, "ui5-$1").toLowerCase(); - const newIssueUrl = `https://github.com/SAP/${moduleNameGuess}/issues/new`; - console.log(""); - console.log( - chalk.dim( - `If you think this is an issue of the UI5 Tooling, you might report it using the ` + - `following URL: `) + - chalk.dim.bold.underline(newIssueUrl)); - } + console.log(""); + console.log( + chalk.dim( + `If you think this is an issue of the UI5 Tooling, you might report it using the ` + + `following URL:`) + + chalk.dim.bold.underline(`https://github.com/SAP/ui5-tooling/issues/new`)); } else { console.log(""); console.log(chalk.dim(