Documentation
¶
Overview ¶
Package interrupt decides what Ctrl-C and SIGTERM do. By default they end the CLI with 130 or 143 and no stack trace. Code that must clean up first, such as `run --wait` cancelling the experiment it started, pushes a handler for as long as it runs.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Push ¶
Push runs fn when the CLI is interrupted, before it exits, until the returned pop is called. Handlers run most recent first.
func RunHandlers ¶
RunHandlers runs what is registered for sig, most recent first, without exiting. The signal handler calls it before exiting; tests call it to stand in for Ctrl-C.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.