Sha256: 1daf4ca9d2820dcf3b991ed11e305ea73f3ad659a6b656dfc90481d029c8bb59
Contents?: true
Size: 659 Bytes
Versions: 5
Compression:
Stored size: 659 Bytes
Contents
#!/usr/bin/env ruby $LOAD_PATH.push File.expand_path('../../lib', __FILE__) require 'optparse' require 'rubrowser' OPTIONS = { port: 9000, files: ARGV.empty? ? ['.'] : ARGV } OptionParser.new do |opts| opts.banner = "Usage: #{__FILE__} [options] [file] ..." opts.on('-pPORT', '--port=PORT', 'Specify port number for server, default = 9000') do |port| OPTIONS[:port] = port.to_i end opts.on('-v', '--version', 'Print Rubrowser version') do puts "Rubrowser #{Rubrowser::VERSION}" exit end opts.on('-h', '--help', 'Prints this help') do puts opts exit end end.parse! require 'server' Rubrowser::Server.start(OPTIONS)
Version data entries
5 entries across 5 versions & 1 rubygems
Version | Path |
---|---|
rubrowser-0.2.2 | bin/rubrowser |
rubrowser-0.2.1 | bin/rubrowser |
rubrowser-0.2.0 | bin/rubrowser |
rubrowser-0.1.6 | bin/rubrowser |
rubrowser-0.1.5 | bin/rubrowser |