Sha256: abad82374b7caef5ab11fe4d7641ae8705fe4a8f1f36e74d3e9ddd41af4524c5
Contents?: true
Size: 567 Bytes
Versions: 6
Compression:
Stored size: 567 Bytes
Contents
# Git helper module class CfnFlow::Git class << self def sha command = "git rev-parse --verify HEAD" result = `#{command}`.chomp unless $?.success? raise Thor::Error.new("Error running `#{command}`") end result end def check_status unless `git status -s`.empty? raise Thor::Error.new("Git working directory is not clean. Please commit or reset changes in order to release.") end unless $?.success? raise Thor::Error.new("Error running `git status`") end end end end
Version data entries
6 entries across 6 versions & 1 rubygems