3
0
corteza/pkg/cli/context.go
Denis Arh 5a9bce44e8 Cleanup internal, vendors, cleanup cmd/*
Introduces /pkg for non-intenral packages
2019-05-24 12:44:56 +02:00

17 lines
351 B
Go

package cli
import (
"context"
ctxwrap "github.com/SentimensRG/ctx"
"github.com/SentimensRG/ctx/sigctx"
)
// Context is small wrapper that returns sig-term bound context
//
// This can be used as (proper) background context that properly terminates
// all subroutines.
func Context() context.Context {
return ctxwrap.AsContext(sigctx.New())
}