signal

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Apr 21, 2021 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Handle

func Handle(stderr io.Writer, callback func())

Handle calls the function "callback" when the sinal is sent. This is useful to support canceling by signal. Usage:

c, cancel := context.WithCancel(ctx)
go signal.Set(os.Stderr, cancel)
...

Types

This section is empty.

Jump to

Keyboard shortcuts

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