wireguard-tools
Version:
The best way to interact with WireGuard from Node
14 lines (13 loc) • 425 B
TypeScript
interface Options {
/** Function to run when data is returned from exec */
onData?: (data: string) => any;
/** Function to run when error occurs */
onError?: (err: string) => any;
/** Function to run when exec ends */
onClose?: (code: number) => any;
}
/**
* A better exec with promises etc.
*/
export declare const exec: (command: string, opts?: Options | undefined) => Promise<string>;
export {};