Class: Git

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

Class Method Summary collapse

Class Method Details

.branchObject



2
3
4
5
6
7
8
# File 'lib/git.rb', line 2

def self.branch
    begin
`git branch`.scan(/\* ([.\w-]+)/)[0][0]
 rescue
  ''
 end
end