add blocking example to readme

This commit is contained in:
John Roesler 2024-01-17 11:50:33 -06:00
parent 800821c923
commit 86d00630cf
No known key found for this signature in database
GPG Key ID: 3AA260B9FCA0A6E1
1 changed files with 5 additions and 0 deletions

View File

@ -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 {