Method: RuboCop::CLI#trap_interrupt
- Defined in:
- lib/rubocop/cli.rb
#trap_interrupt(runner) ⇒ Object
40 41 42 43 44 45 46 47 |
# File 'lib/rubocop/cli.rb', line 40 def trap_interrupt(runner) Signal.trap('INT') do exit!(1) if runner.aborting? runner.abort $stderr.puts $stderr.puts 'Exiting... Interrupt again to exit immediately.' end end |