Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
var Echo = script.Echo
Echo returns a pipe containing the supplied string.
var File = script.File
File returns a *Pipe associated with the specified file. This is useful for starting pipelines. If there is an error opening the file, the pipe's error status will be set.
var FindFiles = script.FindFiles
FindFiles takes a directory path and returns a pipe listing all the files in the directory and its subdirectories recursively, one per line, like Unix `find -type f`. If the path doesn't exist or can't be read, the pipe's error status will be set.
var ListFiles = script.ListFiles
ListFiles creates a pipe containing the files and directories matching the supplied path, one per line. The path may be a glob, conforming to filepath.Match syntax.
Functions ¶
func ExecOutput ¶
ExecOutput runs an external command and returns the contents of the pipe.
func ExecStdout ¶
ExecStdout runs an external command and writes the contents of the pipe to the program's standard output.
Types ¶
type Pipe ¶
Pipe represents a pipe object with an associated ReadAutoCloser. https://pkg.go.dev/github.com/bitfield/script#readme-quick-start-unix-equivalents