google / calblink

Blink(1) monitor for Google Calendar
Apache License 2.0
44 stars 14 forks source link

Move to golang ExternalNow or a similar API #18

Open kazrakcom opened 2 years ago

kazrakcom commented 2 years ago

The code currently avoids oversleeping due to machine sleep by not sleeping for more than 5 minutes at a time - decidedly suboptimal.

The ideal solution would be to use the ExternalNow API when it's available: https://github.com/golang/go/issues/36141

Alternate solutions include using Unix nanosleep or similar.