Module: Gitit::CommandExecutor

Included in:
Branch, Branches, Config, Status
Defined in:
lib/gitit/command_executor.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#repoObject (readonly)

Returns the value of attribute repo.



6
7
8
# File 'lib/gitit/command_executor.rb', line 6

def repo
  @repo
end

Instance Method Details

#execute_command(command) ⇒ Object



8
9
10
11
# File 'lib/gitit/command_executor.rb', line 8

def execute_command(command)
  gitCommand = ['git', command].join(' ')
  `(cd #{@repo.location} && #{gitCommand} 2>&1)`
end