Skip to content

Instantly share code, notes, and snippets.

@dbussink
Created October 6, 2008 18:16
Show Gist options
  • Save dbussink/15089 to your computer and use it in GitHub Desktop.
Save dbussink/15089 to your computer and use it in GitHub Desktop.
alarm = Thread.new(self) { sleep(5); Thread.main.wakeup }
puts "Going to sleep for 1000 seconds at #{Time.new}…"
sleep(10000); puts "Woke up at #{Time.new}!"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment