Sha256: 23974bf0657f89cc6255d8694f240af99865d301fd849887a5fac186a5f2c0e5
Contents?: true
Size: 887 Bytes
Versions: 6
Compression:
Stored size: 887 Bytes
Contents
require_relative 'application' require_relative 'configuration' module Vedeu class Launcher # :nocov: def initialize(argv, stdin = STDIN, stdout = STDOUT, stderr = STDERR, kernel = Kernel) @argv = argv @stdin = stdin @stdout = stdout @stderr = stderr @kernel = kernel @exit_code = 1 end def execute! $stdin, $stdout, $stderr = @stdin, @stdout, @stderr Application.start(configuration) @exit_code = 0 rescue StandardError => uncaught_exception Vedeu.error(uncaught_exception) ensure $stdin, $stdout, $stderr = STDIN, STDOUT, STDERR @kernel.exit(@exit_code) end private attr_reader :argv def configuration Configuration.configure(argv) end # :nocov: end end
Version data entries
6 entries across 6 versions & 1 rubygems