diff options
Diffstat (limited to 'runner/run.go')
-rw-r--r-- | runner/run.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/runner/run.go b/runner/run.go index 4527bea..04f1907 100644 --- a/runner/run.go +++ b/runner/run.go @@ -6,6 +6,7 @@ import ( "log/slog" "os" "os/signal" + "syscall" "go.sudomsg.com/kit/logging" ) @@ -21,7 +22,7 @@ import ( func LoadWithArgs(args []string, run func(ctx context.Context, fs *flag.FlagSet, args []string) error) { ctx := context.Background() - ctx, stop := signal.NotifyContext(ctx) + ctx, stop := signal.NotifyContext(ctx, os.Interrupt, syscall.SIGTERM) defer stop() defer func() { |