shell

package
v0.0.0-...-598a827 Latest Latest
Warning

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

Go to latest
Published: Sep 28, 2021 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CmdRun

func CmdRun(ctx context.Context, bashScript string, output chan *string) (err kv.Error)

CmdRun contains a function that will run a bash script without argument and will pass results back using the channel supplied by the caller. Exit codes will be communicated via the err return. The output channel will be closed on completion.

func PythonRun

func PythonRun(testFiles map[string]os.FileMode, tmpDir string, script string, keepLines uint) (output []string, err kv.Error)

PythonRun will use the set of test files to start a python process that will return the console output and/or an error. The caller can specify the max size of the buffer used to hold the last (keepLines) of lines from the console. If tmpDir is specified that directory will be used to run the process and will not be removed after the function completes, in the case it is blank then the function will generate a directory run the python in it then remove it.

Types

This section is empty.

Jump to

Keyboard shortcuts

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