Help us shape the future of Go! Take the 2026 Go Developer Survey

process

package
v0.239.0-rc.2 Latest Latest
Warning

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

Go to latest
Published: Oct 28, 2026 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Command

func Command(name string, args ...string) *exec.Cmd

Command is exec.Command for a child that must never open its own console window. On windows a console child of a parent without a console gets a fresh window, so infer running under a GUI host flashes one per spawn.

func CommandContext

func CommandContext(ctx context.Context, name string, args ...string) *exec.Cmd

CommandContext is exec.CommandContext with the same console suppression as Command.

func KillTreeOnCancel added in v0.233.2

func KillTreeOnCancel(cmd *exec.Cmd)

KillTreeOnCancel kills the command and every process it started on timeout or cancel, on every platform, so a script's children die too and stop holding its output pipes open. A descendant whose parent already exited is reparented out of the tree and survives: job objects or cgroups if that ever shows up.

Types

This section is empty.

Jump to

Keyboard shortcuts

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