INNER CODE UNIT · TypeScript

main

UfoMiao/zcf · src/cli.ts:6

async function main(): Promise<void> {
  const cli = cac('zcf')
  await setupCommands(cli)
  // cac.parse() invokes the matched action but does not await it; exiting here
  // would drop interactive menu work (uninstall/update) and swallow failures as 0.
  cli.parse(process.argv, { run: false })
  await cli.runMatchedCommand()
}

main().catch((error) => {
  console.error(error)
  process.exitCode = 1
})

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…