Sha256: ca1a1cbb3b4f2a2b48d4717c735eb433a654560ff9ddb9c5d131b3f793cb0249
Contents?: true
Size: 735 Bytes
Versions: 19
Compression:
Stored size: 735 Bytes
Contents
require "optparse" module GitCurate module App # Runs the application and returns an exit status which should be passed to exit() by # the caller of this function. def self.main parser = GitCurate::CLIParser.new continue = parser.parse(ARGV) # will throw on error return EXIT_SUCCESS unless continue runner = GitCurate::Runner.new(parser.parsed_options) # Args not parsed by the CLIParser are passed to Runner. runner.run(ARGV) rescue SystemCommandError => error $stderr.puts(error.message) error.exit_status rescue OptionParser::InvalidOption puts "Unrecognized option" puts "For help, enter `git curate -h`" EXIT_FAILURE end end end
Version data entries
19 entries across 19 versions & 1 rubygems