Sha256: da734006ff82c7c1498c25a25898e4dbe2f335ef1d9f3a64b6250f08c7af16fc
Contents?: true
Size: 1.12 KB
Versions: 2
Compression:
Stored size: 1.12 KB
Contents
#!/usr/bin/env ruby require 'rubygems' libdir = "#{File.expand_path(File.dirname(File.dirname(__FILE__)))}/lib" $LOAD_PATH.unshift libdir unless $LOAD_PATH.include?(libdir) load "#{libdir}/../rerun.gemspec" # defines "$spec" variable, which we read the version from require 'optparse' options = {} opts = OptionParser.new("", 24, ' ') { |opts| opts.banner = "Usage: rerun cmd" opts.separator "" opts.separator "Launches an app, and restarts it when the filesystem changes." opts.separator "See http://github.com/alexch/rerun for more info." opts.separator "" opts.separator "Options:" opts.on_tail("-h", "--help", "--usage", "show this message") do puts opts exit end opts.on_tail("--version", "show version") do puts $spec.version exit end opts.parse! ARGV } #config = ARGV[0] || "config.ru" #abort "configuration #{config} not found" unless File.exist? config # #if config =~ /\.ru$/ && File.read(config)[/^#\\(.*)/] # opts.parse! $1.split(/\s+/) #end if ARGV.empty? puts opts exit end require 'rerun' cmd = ARGV.join(" ") runner = Rerun::Runner.new(cmd, options) runner.start runner.join
Version data entries
2 entries across 2 versions & 2 rubygems
Version | Path |
---|---|
alexch-rerun-0.2.1 | bin/rerun |
rerun-0.2.1 | bin/rerun |