Sha256: a5620aabf8964e22421b11a44f7ff3defaf57ca91559d3f3db640f1f3ac922b0
Contents?: true
Size: 786 Bytes
Versions: 2
Compression:
Stored size: 786 Bytes
Contents
require_relative '../feature/node/merge_exec' module IronWorkerNG module Code class Node < IronWorkerNG::Code::Base include IronWorkerNG::Feature::Node::MergeExec::InstanceMethods def create_runner(zip) zip.get_output_stream(runner) do |runner| runner.write <<RUNNER #!/bin/sh # iron_worker_ng-#{IronWorkerNG.full_version} root() { while [ $# -gt 0 ]; do if [ "$1" = "-d" ]; then printf "%s\n" "$2" break fi done } cd "$(root "$@")" node #{File.basename(@exec.path)} "$@" RUNNER end end def runtime(runtime = nil) 'sh' end def runner '__runner__.sh' end end end end IronWorkerNG::Code::Base.register_type(:name => 'node', :klass => IronWorkerNG::Code::Node)
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
iron_worker_ng-0.4.3 | lib/iron_worker_ng/code/node.rb |
iron_worker_ng-0.4.2 | lib/iron_worker_ng/code/node.rb |