Sha256: 97865d117a10b3c93d6dee17d136ae29f9b32376d5555bca5f49fc7b26831b69

Contents?: true

Size: 184 Bytes

Versions: 4

Compression:

Stored size: 184 Bytes

Contents

module SignalTools
  def self.append_trap(signal, &block)
    old_handler = trap(signal) do
      block.call
      old_handler.call if old_handler.respond_to?(:call)
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
dispatch-rider-1.3.0 lib/dispatch-rider/signal_tools.rb
dispatch-rider-1.2.11 lib/dispatch-rider/signal_tools.rb
dispatch-rider-1.2.10 lib/dispatch-rider/signal_tools.rb
dispatch-rider-1.2.9 lib/dispatch-rider/signal_tools.rb