Skip to content

Commit

Permalink
await node:repl
Browse files Browse the repository at this point in the history
  • Loading branch information
antonmedv authored Feb 28, 2023
1 parent 85c9409 commit a3753b1
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ await (async function main() {
return
}
if (argv.repl) {
(await import('./repl.js')).startRepl()
await (await import('./repl.js')).startRepl()
return
}
if (argv.eval) {
Expand Down
5 changes: 2 additions & 3 deletions src/repl.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,12 @@
import chalk from 'chalk'
import os from 'node:os'
import path from 'node:path'
import repl from 'node:repl'
import { inspect } from 'node:util'
import { ProcessOutput, defaults } from './core.js'

export function startRepl() {
export async function startRepl() {
defaults.verbose = false
const r = repl.start({
const r = (await import('node:repl')).start({
prompt: chalk.greenBright.bold('❯ '),
useGlobal: true,
preview: false,
Expand Down

0 comments on commit a3753b1

Please sign in to comment.