Sha256: 4b1b26bd9c3766e90e7a8cf6f240dc71e29ff844b515d5a47b3c2db9c4eb9793
Contents?: true
Size: 434 Bytes
Versions: 92
Compression:
Stored size: 434 Bytes
Contents
require 'singleton' module Specinfra::Backend class ShellScript < Base def initialize @lines = [ "#!/bin/sh", "" ] ObjectSpace.define_finalizer(self, Writer.new(@lines)) end def run_command(cmd, opts={}) @lines << cmd CommandResult.new end class Writer def initialize(lines) @lines = lines end def call(*args) puts @lines end end end end
Version data entries
92 entries across 92 versions & 1 rubygems