Sha256: f325978f1c95745187421e1395c798746a14651c3e49e4e9de3a7e42a44f4f4c

Contents?: true

Size: 327 Bytes

Versions: 4

Compression:

Stored size: 327 Bytes

Contents

class CommandTask < Volt::Task
  def run(command)
  	begin
	    Opal.compile(command, irb: true)
	  rescue RuntimeError => e
	  	# Check to see if we have a parse error
	  	if e.message =~ /An error occurred while compiling/
	  		# Pass that we are continuing
	  		'...continue...'
	  	else
	  		raise
	  	end
	  end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
volt-browser_irb-0.1.4 app/browser_irb/tasks/command_task.rb
volt-browser_irb-0.1.3 app/browser_irb/tasks/command_task.rb
volt-browser_irb-0.1.2 app/browser_irb/tasks/command_task.rb
volt-browser_irb-0.1.0 app/browser_irb/tasks/command_task.rb