source

package
v0.0.0-...-d5d086f Latest Latest
Warning

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

Go to latest
Published: May 27, 2024 License: BSD-3-Clause Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExecBatch

func ExecBatch(args []string, verbose io.Writer, debug bool, stdin io.Reader, stdout, stderr io.Writer, env []string) (int, error)

ExecBatch calls the batchfiles and load the changed variable the batchfile has done.

Types

type Batch

type Batch struct {
	Stdin   io.Reader
	Stdout  io.Writer
	Stderr  io.Writer
	Env     []string
	OnExec  func(int)
	OnDone  func(int)
	Args    []string
	Verbose io.Writer
	Debug   bool
}

Batch is the type that contains the condition when the batchfile executes.

func (Batch) Call

func (batch Batch) Call() (int, error)

Call calls the batchfiles and load the changed variable the batchfile has done.

type System

type System struct {
	Cmdline string
	Stdin   io.Reader
	Stdout  io.Writer
	Stderr  io.Writer
	Env     []string
	OnExec  func(int)
	OnDone  func(int)
}

System is the type that simulates `system` function of the Programming language C. Note: This type does not pick up environment variables or current directories that have changed in child processes.

func (System) Run

func (system System) Run() (int, error)

Run executes the process as System specifies.

Jump to

Keyboard shortcuts

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