Sha256: 151c7375fe2de0919773a52893344c78f6efdae728f364381ad7bb8f9f9b271f
Contents?: true
Size: 581 Bytes
Versions: 1
Compression:
Stored size: 581 Bytes
Contents
require 'neutron' module Neutron::Valac def self.compile(*files, **opts) o = { prog: 'valac', debug: false, type: :object, args: '' }.merge(opts) specific = '' if o[:debug] specific << ' -g' end case o[:type] when :object specific << ' -c' else raise TypeError, "Invalid output type: #{o[:type]}!" end files.each do |file| file = File.expand_path(file) Neutron.execute("#{o[:prog]} #{file} #{specific} -b ./ --thread #{o[:args]}", must_success: true) end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
neutron-0.2.1 | lib/neutron/valac.rb |