Sha256: 96c5c8d2ebabdb8b71bdbe09055c05372d0fced6f414813aef842a943010ab55

Contents?: true

Size: 579 Bytes

Versions: 1

Compression:

Stored size: 579 Bytes

Contents

require 'thegarage/gitx/version'
require 'thegarage/gitx/string_extensions'
require 'thegarage/gitx/git'
require 'thegarage/gitx/github'


module Thegarage
  module Gitx
    BASE_BRANCH = 'master'

    private

    # execute a shell command and raise an error if non-zero exit code is returned
    # return the string output from the command
    def run_cmd(cmd, options = {})
      say "\n$ "
      say cmd.gsub("'", ''), :red
      output = `#{cmd}`
      success = !!$?.to_i
      raise "#{cmd} failed" unless success || options[:allow_failure]
      output
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
thegarage-gitx-1.1.0.alpha lib/thegarage/gitx.rb