@antora/cli
Advanced tools
Comparing version 3.1.0 to 3.1.1
@@ -16,3 +16,2 @@ 'use strict' | ||
function exitWithError (err, opts, msg = undefined) { | ||
const { getLogger, configureLogger } = requireLogger() | ||
let errMessage = String( | ||
@@ -25,2 +24,4 @@ err instanceof Error ? err.message : Object.assign((err = new Error(String(err))), { stack: undefined }).message | ||
if (!msg) msg = errMessage | ||
const { configureLogger, getLogger } = requireLogger() | ||
if (!getLogger) return lastDitchExit(err, msg) | ||
if (!getLogger(null)) { | ||
@@ -43,2 +44,8 @@ configureLogger({ format: 'pretty', level: opts.silent ? 'silent' : 'fatal', failureLevel: 'fatal' }) | ||
function lastDitchExit (err, msg) { | ||
if (msg !== err.message) console.error(msg) | ||
console.error(err) | ||
process.exitCode = process.exitCode || 1 | ||
} | ||
function getTTYColumns () { | ||
@@ -59,3 +66,3 @@ return +process.env.COLUMNS || process.stdout.columns || 80 | ||
} catch { | ||
return fromPath && (requireLogger.cache = require(moduleName)) | ||
return fromPath ? (requireLogger.cache = require(moduleName)) : {} | ||
} | ||
@@ -62,0 +69,0 @@ } |
{ | ||
"name": "@antora/cli", | ||
"version": "3.1.0", | ||
"version": "3.1.1", | ||
"description": "The command line interface for Antora.", | ||
@@ -28,4 +28,4 @@ "license": "MPL-2.0", | ||
"dependencies": { | ||
"@antora/logger": "3.1.0", | ||
"@antora/playbook-builder": "3.1.0", | ||
"@antora/logger": "3.1.1", | ||
"@antora/playbook-builder": "3.1.1", | ||
"@antora/user-require-helper": "~2.0", | ||
@@ -35,3 +35,3 @@ "commander": "~9.4" | ||
"devDependencies": { | ||
"@antora/site-publisher": "3.1.0", | ||
"@antora/site-publisher": "3.1.1", | ||
"@asciidoctor/core": "~2.2", | ||
@@ -38,0 +38,0 @@ "convict": "~6.2", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
12587
233
+ Added@antora/logger@3.1.1(transitive)
+ Added@antora/playbook-builder@3.1.1(transitive)
- Removed@antora/logger@3.1.0(transitive)
- Removed@antora/playbook-builder@3.1.0(transitive)
Updated@antora/logger@3.1.1