cmd

package
v0.1.17 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 5, 2024 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RunCmd

func RunCmd(cmd string, args ...string) error

RunCmd executes a system command without capturing its output.

The function takes the command to be run as the first argument followed by its arguments. For example, to run "ls -l", call RunCmd("ls", "-l").

Returns an error if the command exits with a non-zero status.

func RunCmdCombinedOutput

func RunCmdCombinedOutput(cmd string, args ...string) ([]byte, error)

RunCmdCombinedOutput executes a system command and returns its combined standard output and standard error.

func RunCmdOutput

func RunCmdOutput(cmd string, args ...string) ([]byte, error)

RunCmdOutput executes a system command and returns its standard output.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL