Documentation
¶
Index ¶
- Constants
- func Create(plainCommand string) *exec.Cmd
- func Createf(format string, args ...interface{}) *exec.Cmd
- func ExecuteCommand(command *exec.Cmd) string
- func ExecuteCommandForUserInput(cmd *exec.Cmd)
- func ExecuteCommandLongRunning(command *exec.Cmd) string
- func ExecuteCommandVerbose(command *exec.Cmd) string
- func ExecutesSuccessfully(command *exec.Cmd) bool
Constants ¶
const DOUBLE_QUOTE = "{DOUBLE_QUOTE}"
const SPACE_WITHIN_QUOTE = "{SPACE_WITHIN_QUOTE}"
Variables ¶
This section is empty.
Functions ¶
func Create ¶
Create creates a command from a single string This allows you to pass parameters which include spaces as commands. You just need to add "double-quotes" around the parameter and it will be treated as one parameter and not be splitted by whitespace.
func ExecuteCommand ¶
ExecuteCommand executes the command and respects the current verbosity level
func ExecuteCommandForUserInput ¶
ExecuteCommandForUserInput starts the given command and waits either for command completion or for a user input (ENTER). If there is a user input a Kill-Signal will be sent to the command-process and the execution is continued.
func ExecuteCommandLongRunning ¶
ExecuteCommandLongRunning runs the given command and starts a async spinner to tell the user to be patient
func ExecuteCommandVerbose ¶
ExecuteCommandVerbose executes the given command, pipes to stdout and stderr and returns the stdout for further processing, no matter what the verbosity is
func ExecutesSuccessfully ¶
Types ¶
This section is empty.