class Git::Base

Public Class Methods

command(command = '', opts = '') click to toggle source

wrapper for git commands

# File lib/git/base.rb, line 13
def self.command(command = '', opts = '')
  IO.popen("git #{command} #{opts} 2>&1") # 2>&1 surpresses stderr
end
command_output(command = '', opts = '') click to toggle source

wrapper for command method which returns the output

# File lib/git/base.rb, line 5
def self.command_output(command = '', opts = '')
  f = command(command, opts)
  output = f.readlines.join
  f.close
  output
end