Sha256: 97b789dc7e73fc498244a2116ce84f8c9210290d6280d68f9aa764e78b742314

Contents?: true

Size: 442 Bytes

Versions: 11

Compression:

Stored size: 442 Bytes

Contents

module KubesGoogle::Util
  module Sh
  private
    def sh(command)
      logger.debug "=> #{command}"
      success = system(command)
      unless success
        logger.info "WARN: Running #{command}"
      end
      success
    end

    def capture(command)
      out = `#{command}`
      unless $?.exitstatus == 0
        logger.info "ERROR: Running #{command}"
        logger.info out
        exit 1
      end
      out
    end
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
kubes_google-0.3.11 lib/kubes_google/util/sh.rb
kubes_google-0.3.10 lib/kubes_google/util/sh.rb
kubes_google-0.3.9 lib/kubes_google/util/sh.rb
kubes_google-0.3.8 lib/kubes_google/util/sh.rb
kubes_google-0.3.7 lib/kubes_google/util/sh.rb
kubes_google-0.3.6 lib/kubes_google/util/sh.rb
kubes_google-0.3.5 lib/kubes_google/util/sh.rb
kubes_google-0.3.4 lib/kubes_google/util/sh.rb
kubes_google-0.3.3 lib/kubes_google/util/sh.rb
kubes_google-0.3.2 lib/kubes_google/util/sh.rb
kubes_google-0.3.1 lib/kubes_google/util/sh.rb