commands

package
v0.1.5 Latest Latest
Warning

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

Go to latest
Published: Oct 23, 2019 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const DOUBLE_QUOTE = "{DOUBLE_QUOTE}"
View Source
const SPACE_WITHIN_QUOTE = "{SPACE_WITHIN_QUOTE}"

Variables

This section is empty.

Functions

func Create

func Create(plainCommand string) *exec.Cmd

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 Createf

func Createf(format string, args ...interface{}) *exec.Cmd

Createf creates a command from a formatted input string

func ExecuteCommand

func ExecuteCommand(command *exec.Cmd) (string, error)

func ExecuteCommandLongRunning

func ExecuteCommandLongRunning(command *exec.Cmd) (string, error)

ExecuteCommandLongRunning runs the given command and starts a async spinner to tell the user to be patient

Types

This section is empty.

Jump to

Keyboard shortcuts

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