Class: BuildMaster::CvsDriver
- Inherits:
-
Object
- Object
- BuildMaster::CvsDriver
- Defined in:
- lib/buildmaster/project/cvs_driver.rb
Class Method Summary collapse
Instance Method Summary collapse
- #checkout ⇒ Object
- #command(command) ⇒ Object
- #commit(comment) ⇒ Object
-
#initialize(cvs_info, working_directory) ⇒ CvsDriver
constructor
A new instance of CvsDriver.
- #tag(name) ⇒ Object
- #update(option = '') ⇒ Object
Constructor Details
#initialize(cvs_info, working_directory) ⇒ CvsDriver
Returns a new instance of CvsDriver.
23 24 25 26 27 |
# File 'lib/buildmaster/project/cvs_driver.rb', line 23 def initialize(cvs_info, working_directory) @cvs_info = cvs_info @working_directory = working_directory @cotta = @working_directory.cotta end |
Class Method Details
Instance Method Details
#checkout ⇒ Object
33 34 35 |
# File 'lib/buildmaster/project/cvs_driver.rb', line 33 def checkout() @cotta.shell("cvs -d #{@cvs_info.root} co -d #{@working_directory.path} #{@cvs_info.repository}") end |
#command(command) ⇒ Object
29 30 31 |
# File 'lib/buildmaster/project/cvs_driver.rb', line 29 def command(command) @cotta.shell "cvs -d #{@cvs_info.root} #{command} #{@working_directory.path}" end |
#commit(comment) ⇒ Object
48 49 50 |
# File 'lib/buildmaster/project/cvs_driver.rb', line 48 def commit(comment) command("commit -m \"#{comment}\"") end |
#tag(name) ⇒ Object
44 45 46 |
# File 'lib/buildmaster/project/cvs_driver.rb', line 44 def tag(name) command("tag #{name}") end |
#update(option = '') ⇒ Object
37 38 39 40 41 42 |
# File 'lib/buildmaster/project/cvs_driver.rb', line 37 def update(option='') if (option.length > 0) option = ' ' + option end command("update#{option}") end |