Class: Ive::Git

Inherits:
Object
  • Object
show all
Defined in:
lib/ive/git.rb

Class Method Summary collapse

Class Method Details

.changes?Boolean

Returns:

  • (Boolean)


6
7
8
9
# File 'lib/ive/git.rb', line 6

def changes?
  git = ::Git.open Ive.path
  git.status.changed.count > 0
end

.commit(version) ⇒ Object



11
12
13
14
15
16
# File 'lib/ive/git.rb', line 11

def commit version
  git = ::Git.open Ive.path
  git.add all: true
  git.commit "Version bump"
  git.add_tag version
end