Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/readme_manager/mod.ts>runCommand

helps manage and harmonise READMEs in many repositories with template files
Latest
variable runCommand
Re-export
import { runCommand } from "https://deno.land/x/readme_manager@v3.0.0/mod.ts";

Run a shell command.

import { runCommand } from "./utils.ts"
const output = await runCommand("ls", (errorMsg: string, error?: Error) => {}, true)
try {
  const failing = await runCommand(">&2 echo error", (errorMsg: string, error?: Error) => {})
} catch (e) {
  console.log(e)
}

type

(
command: string[],
error: (message: string, error?: Error) => void,
allowFail?: boolean,
) => unknown