process

package
v0.4.48 Latest Latest
Warning

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

Go to latest
Published: Aug 18, 2026 License: Apache-2.0 Imports: 4 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package process provides utilities for managing the current system process.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Exit

func Exit(code int)

Exit runs the registered exit handlers, as if the os.Interrupt signal had been sent, and then terminates the process with the given status code. Exit blocks until the process terminates if it has already been called elsewhere.

func SetExitHandler

func SetExitHandler(handler func())

SetExitHandler registers the given handler function to run when receiving os.Interrupt or SIGTERM signals. Registered handlers are executed in reverse order of when they were set.

func SetSignalHandler

func SetSignalHandler(signal os.Signal, handler func())

SetSignalHandler registers the given handler function to run when receiving the specified signal. Registered handlers are executed in reverse order of when they were set.

Types

This section is empty.

Jump to

Keyboard shortcuts

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