diff options
author | Jamis Buck <jamis@37signals.com> | 2005-08-27 14:42:58 +0000 |
---|---|---|
committer | Jamis Buck <jamis@37signals.com> | 2005-08-27 14:42:58 +0000 |
commit | 959e06a0fc1dd3b85aeb5d0d005eff2a02eb547e (patch) | |
tree | 0e141dd1f36a31edd6c3683bbc08df5956f1e520 /switchtower/lib/switchtower/scm/cvs.rb | |
parent | b80f0e2ff3a51e6166e4e29b87a7380f42529e7a (diff) | |
download | rails-959e06a0fc1dd3b85aeb5d0d005eff2a02eb547e.tar.gz rails-959e06a0fc1dd3b85aeb5d0d005eff2a02eb547e.tar.bz2 rails-959e06a0fc1dd3b85aeb5d0d005eff2a02eb547e.zip |
SwitchTower: log checkouts to a "revisions.log" file
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2060 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'switchtower/lib/switchtower/scm/cvs.rb')
-rw-r--r-- | switchtower/lib/switchtower/scm/cvs.rb | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/switchtower/lib/switchtower/scm/cvs.rb b/switchtower/lib/switchtower/scm/cvs.rb index db3eae9261..794a3b5212 100644 --- a/switchtower/lib/switchtower/scm/cvs.rb +++ b/switchtower/lib/switchtower/scm/cvs.rb @@ -44,12 +44,11 @@ module SwitchTower cvs_rsh = configuration[:cvs_rsh] || ENV['CVS_RSH'] || "ssh" command = <<-CMD - if [[ ! -d #{actor.release_path} ]]; then - cd #{configuration.releases_path}; - CVS_RSH="#{cvs_rsh}" #{cvs} -d #{configuration.repository} -Q co -D "#{latest_revision}" -d #{File.basename(actor.release_path)} #{actor.application}; - fi + cd #{configuration.releases_path}; + CVS_RSH="#{cvs_rsh}" #{cvs} -d #{configuration.repository} -Q co -D "#{latest_revision}" -d #{File.basename(actor.release_path)} #{actor.application}; CMD - actor.run(command) do |ch, stream, out| + + run_checkout(actor, command) do |ch, stream, out| prefix = "#{stream} :: #{ch[:host]}" actor.logger.info out, prefix if out =~ %r{password:} @@ -64,7 +63,7 @@ module SwitchTower end private - + def cvs_log(path) `cd #{path || "."} && cvs -q log -N -rHEAD` end |