Sha256: f9f2f21435ec5feda5f7b18ced08015e7ed854ebdef5da990e6646304b4becd5
Contents?: true
Size: 365 Bytes
Versions: 11
Compression:
Stored size: 365 Bytes
Contents
require 'open4' module Bricks module Helper def run(cd, *args) status = 0 msg = nil err = nil cd ||= '.' Dir.chdir(cd) do status = Open4::popen4(*args) do |pid, stdin, stdout, stderr| msg = stdout.read err = stderr.read end end return status == 0, msg, err end end end
Version data entries
11 entries across 11 versions & 1 rubygems