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

x/ayonli_jsext/cli.ts>sudo

A JavaScript extension package for building strong and modern applications.
Latest
function sudo
import { sudo } from "https://deno.land/x/ayonli_jsext@v0.9.72/cli.ts";

Executes a command with elevated privileges using sudo (or UAC in Windows).

Examples

Example 1

import { sudo } from "@ayonli/jsext/cli";

await sudo("apt", ["install", "build-essential"]);

Parameters

cmd: string
args: string[]
optional
options: SudoOptions = [UNSUPPORTED]