Sha256: 13e1c66191a0a9988edda22cb9ef357c51f17fa5e6578daf1cc7bc317cbefb9f
Contents?: true
Size: 644 Bytes
Versions: 1
Compression:
Stored size: 644 Bytes
Contents
# Simple demo Rakefile to autorun samples in current directory # adjust path to rp5 executable, and or opts as required SAMPLES_DIR = './' desc 'run demo' task default: [:demo] desc 'demo' task :demo do samples_list.shuffle.each { |sample| run_sample sample } end def samples_list files = [] Dir.chdir(SAMPLES_DIR) Dir.glob('*.rb').each do |file| files << File.join(SAMPLES_DIR, file) unless file.end_with? 'agent.rb' end files end def run_sample(sample_name) puts "Running #{sample_name}...quit to run next sample" open("|k9 run #{sample_name}", 'r') do |io| while l = io.gets puts(l.chop) end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
geomerative-0.3.2-java | examples/Rakefile |