Module: Gitit::CommandExecutor

Included in:
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.



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

def repo
  @repo
end

Instance Method Details

#executeCommand(command) ⇒ Object



11
12
13
14
15
# File 'lib/gitit/command_executor.rb', line 11

def executeCommand(command)
  gitCommand = ["git", command].join(" ")
  result = `(cd #{@repo.location} && #{gitCommand})`
  return result
end