Sha256: c2d4a3d8bc1047ca03d330b3d6ad1fcd7f9ac228d6fda15a092c0642b68d38f4

Contents?: true

Size: 878 Bytes

Versions: 3

Compression:

Stored size: 878 Bytes

Contents

#!/usr/bin/env ruby

require File.expand_path(File.dirname(__FILE__) + '/../lib/starting_blocks.rb')

options = {}

def display value
end

require 'starting_blocks-blinky' if ARGV.include? '--blinky'
require 'starting_blocks-growl' if ARGV.include? '--growl'

options[:verbose]     = ARGV.include? '--verbose'
options[:no_vendor]   = ARGV.include?('--vendor') == false
options[:use_bundler] = Dir['Gemfile'].count > 0

def run_all_specs options
  files = ['**/*_spec.rb*', '**/*_test.rb*', '**/test_*.rb*'].map do |d|
    Dir[d].
      select { |f| File.file?(f) }.
      map    { |x| File.expand_path(x) }
  end.flatten

  StartingBlocks::Runner.new(options).run_files files
end

if ARGV.include? '--watch'
  StartingBlocks::Watcher.start_watching Dir, options
elsif ARGV.include? '--off'
  StartingBlocks::Extensions::BlinkyLighting.turn_off!
else
  run_all_specs options
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
starting_blocks-0.1.0 bin/sb
starting_blocks-0.0.32 bin/sb
starting_blocks-0.0.31 bin/sb