From 86d00630cf2f5a743f7eb389ac8fae364aecaf99 Mon Sep 17 00:00:00 2001 From: John Roesler Date: Wed, 17 Jan 2024 11:50:33 -0600 Subject: [PATCH] add blocking example to readme --- README.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/README.md b/README.md index 5c3a301..19095ec 100644 --- a/README.md +++ b/README.md @@ -53,6 +53,11 @@ func main() { // start the scheduler s.Start() + // block until you are ready to shut down + select { + case <-time.After(time.Minute): + } + // when you're done, shut it down err = s.Shutdown() if err != nil {