Sha256: 233853dde6bed0cdb7dd1f2eba76d28a3aac4a7c6bbc07a81ec6581b148d2646

Contents?: true

Size: 307 Bytes

Versions: 1

Compression:

Stored size: 307 Bytes

Contents

# coding: utf-8

module Githelp
  def branches
    `git branch`.split(/\n/).map { |line|
      line.chomp!
      line.sub(/^../,'')
    }
  end
  
  def branch
    `git branch`.split(/\n/).map { |line|
      line.chomp!
      if line =~ /^\* (.*)$/ then
        return $1
      end
    }
    ''
  end
end


Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
githelp-0.1.0 lib/githelp/branches.rb