0.1.3 • Published 6 years ago

commandland v0.1.3

Weekly downloads
15
License
MIT
Repository
github
Last release
6 years ago

commandland

I make executing commands look good.

Nah

Feature
Live stdout with ASCII colors
Live stdin
(Or keep live stdout/stdin silent)
Capture output as string
Exit code and signal capture
Session record & playback

Run a command

import { run } from "commandland"
let { code, out } = await run("ls", ["/"])

Execution options

OptionExamplePurpose
args["/"]Command arguments
command"ls"Command to execute
cols, rows100, 100Column and rows for pty
cwdprocess.env.HOMEWorking directory for pty
envprocess.envEnvironment for pty
onData()=>{}Pty data callback
recordfalseRecord the session
silentfalseExecute without stdout
stdinfalseAllow stdin input

Replay a session

import { run, replay } from "commandland"
let { session } = await run("ls", ["/"], { record: true })
await replay(session)
0.1.3

6 years ago

0.1.2

6 years ago

0.1.1

6 years ago

0.1.0

6 years ago

0.0.8

6 years ago

0.0.7

6 years ago

0.0.6

6 years ago

0.0.5

6 years ago

0.0.4

6 years ago

0.0.3

6 years ago

0.0.2

6 years ago

0.0.1

6 years ago