jnicklas/evergreen — pull request #59 by spraints (2012-06-21 19:13:53+00:00)
Title: Shutdown on ctrl-C.

Make `evergreen serve` exit on `^C`.

In my environment (rails 3.0.9, capybara 1.1.2, thin 1.3.1, evergreen 1.0.0, etc), the above wasn't happening. AFAICT, nothing but `kill -9` made it stop.

I was able to reproduce the un-SIGINT-able sleep by running this:

```ruby
require 'capybara'
app = lambda do |env|
[200, {'Content-type' => 'text/plain'}, 'ok']
end
server = Capybara::Server.new(app)
server.boot
#trap("SIGINT") { exit 0 }
puts server.url('/').inspect
sleep
puts 'done!'
```

Uncommenting the `trap` call makes `^C` work as expected.