Add spinner to vm stop command
This commit is contained in:
parent
b73ff47151
commit
6a8bbfd407
|
|
@ -60,8 +60,14 @@ export function register(program: Command) {
|
|||
.command("stop")
|
||||
.description("Stop the VM")
|
||||
.action(async () => {
|
||||
await vm.stop()
|
||||
console.log("✔ VM stopped")
|
||||
const spin = spinner("Stopping VM")
|
||||
try {
|
||||
await vm.stop()
|
||||
spin.succeed("VM stopped")
|
||||
} catch (err) {
|
||||
spin.fail(String((err as Error).message ?? err))
|
||||
process.exit(1)
|
||||
}
|
||||
})
|
||||
|
||||
vmCmd
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user