Class: SVNx::CommandLine

Inherits:
System::CommandLine show all
Defined in:
lib/svnx/command.rb

Instance Attribute Summary

Attributes inherited from System::CommandLine

#output

Instance Method Summary collapse

Methods inherited from System::CommandLine

#<<, #execute, #to_command

Constructor Details

#initialize(subcmd, args = Array.new) ⇒ CommandLine

Returns a new instance of CommandLine.



12
13
14
15
16
17
18
19
# File 'lib/svnx/command.rb', line 12

def initialize subcmd, args = Array.new
  info "args: #{args}"
  cmdargs = [ 'svn', subcmd ]
  cmdargs << '--xml' if uses_xml?
  cmdargs.concat args
  info "cmdargs: #{cmdargs}"
  super cmdargs
end

Instance Method Details

#uses_xml?Boolean

Returns:

  • (Boolean)


21
22
23
# File 'lib/svnx/command.rb', line 21

def uses_xml?
  true
end