Sha256: 84ca660b19ac40f9e4e7ff152a1df7c97b9e15e820afaefa4a76d63b8475c081
Contents?: true
Size: 448 Bytes
Versions: 2
Compression:
Stored size: 448 Bytes
Contents
# frozen_string_literal: true require "open3" module Setup module_function def execute(cmd) puts "Running #{cmd}" status, out, err = nil Open3.popen3(cmd) do |stdin, stdout, stderr, wait_thr| _pid = wait_thr.pid stdin.close out = stdout.read err = stderr.read status = wait_thr.value end if !status.success? puts "Failed to run #{cmd}" puts err exit 1 end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
dry-view-0.7.0 | bin/setup_helpers.rb |
dry-view-0.6.0 | bin/setup_helpers.rb |