Commit c3f2d39
src/core.ts
@@ -56,7 +56,7 @@ function syncCwd() {
function initStore(): Options {
const context = {
- verbose: true,
+ verbose: (global as any).ZX_VERBOSE ?? true,
cwd: process.cwd(),
env: process.env,
shell: true,
@@ -66,7 +66,6 @@ function initStore(): Options {
log,
}
storage.enterWith(context)
- if (process.env.ZX_VERBOSE) $.verbose = process.env.ZX_VERBOSE == 'true'
try {
$.shell = which.sync('bash')
$.prefix = 'set -euo pipefail;'
src/repl.ts
@@ -20,7 +20,7 @@ import chalk from 'chalk'
import { ProcessOutput } from './core.js'
export function startRepl() {
- process.env.ZX_VERBOSE = 'false'
+ (global as any).ZX_VERBOSE = false
const r = repl.start({
prompt: chalk.greenBright.bold('❯ '),
useGlobal: true,