Class: Capistrano::SCM::Darcs

Inherits:
Base
  • Object
show all
Defined in:
lib/capistrano/scm/darcs.rb

Overview

An SCM module for using darcs as your source control tool. Use it by specifying the following line in your configuration:

set :scm, :darcs

Also, this module accepts a :darcs configuration variable, which (if specified) will be used as the full path to the darcs executable on the remote machine:

set :darcs, "/opt/local/bin/darcs"

Instance Attribute Summary

Attributes inherited from Base

#configuration

Instance Method Summary collapse

Methods inherited from Base

#current_revision, #diff, #initialize, #latest_revision, #update

Constructor Details

This class inherits a constructor from Capistrano::SCM::Base

Instance Method Details

#checkout(actor) ⇒ Object

Check out (on all servers associated with the current task) the latest revision. Uses the given actor instance to execute the command.



19
20
21
22
23
# File 'lib/capistrano/scm/darcs.rb', line 19

def checkout(actor)
  darcs = configuration[:darcs] ? configuration[:darcs] : "darcs"
  revision = configuration[:revision] ? %(--to-match "#{configuration.revision}") : ""
  run_checkout(actor, "#{darcs} get -q --set-scripts-executable #{revision} #{configuration.repository} #{actor.release_path};")
end