1
0
Fork 0
mirror of https://github.com/capistrano/capistrano synced 2023-03-27 23:21:18 -04:00

Fix for deploy:pending while using git. git log requires a .. following the from revision even if the to revision isn't specified; otherwise the log goes backwards starting at the from revision instead of finding all newer commits after the current from revision. For example, git log <from_revision>.. is required instead of just git log <from_revision>

This commit is contained in:
Ryan McGeary 2008-05-05 23:07:22 -04:00
parent 61808dd6e0
commit 230b210995
2 changed files with 2 additions and 3 deletions

View file

@ -202,8 +202,7 @@ module Capistrano
# Returns a log of changes between the two revisions (inclusive).
def log(from, to=nil)
from << "..#{to}" if to
scm :log, from
scm :log, "#{from}..#{to}"
end
# Getting the actual commit id, in case we were passed a tag

View file

@ -45,7 +45,7 @@ class DeploySCMGitTest < Test::Unit::TestCase
end
def test_log
assert_equal "git log master", @source.log('master')
assert_equal "git log master..", @source.log('master')
assert_equal "git log master..branch", @source.log('master', 'branch')
end