Sha256: dc9c0cc4e7b6f5844ad2ca9a594ae7f0e2928863a19ffde3543fdfbe19cf320f
Contents?: true
Size: 646 Bytes
Versions: 24
Compression:
Stored size: 646 Bytes
Contents
# frozen_string_literal: true require "English" module ReactOnRails module GitUtils def self.uncommitted_changes?(message_handler) return false if ENV["COVERAGE"] == "true" status = `git status --porcelain` return false if $CHILD_STATUS.success? && status.empty? error = if $CHILD_STATUS.success? "You have uncommitted code. Please commit or stash your changes before continuing" else "You do not have Git installed. Please install Git, and commit your changes before continuing" end message_handler.add_error(error) true end end end
Version data entries
24 entries across 24 versions & 1 rubygems