shellx

package
v3.14.0-alpha Latest Latest
Warning

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

Go to latest
Published: Dec 6, 2021 License: GPL-3.0 Imports: 5 Imported by: 0

Documentation

Overview

Package shellx runs external commands.

Index

Constants

This section is empty.

Variables

View Source
var ErrNoCommandToExecute = errors.New("shellx: no command to execute")

ErrNoCommandToExecute means that the command line is empty.

Functions

func Run

func Run(logger Logger, name string, arg ...string) error

Run executes the specified command with the specified args.

func RunCommandline

func RunCommandline(logger Logger, cmdline string) error

RunCommandline executes the given command line.

func RunQuiet

func RunQuiet(name string, arg ...string) error

RunQuiet is like Run but it does not emit any output.

Types

type Logger

type Logger interface {
	Infof(format string, v ...interface{})
}

Logger is the logger expected by this package.

Jump to

Keyboard shortcuts

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