lib/danger/scm_source/git_repo.rb in danger-additional-logging-0.0.8 vs lib/danger/scm_source/git_repo.rb in danger-additional-logging-0.0.9
- old
+ new
@@ -97,15 +97,15 @@
else
puts "The commit #{commitish} DOES NOT exist in #{branch}"
end
puts "Is shallow repo:"
- exec("rev-parse --is-shallow-repository")
+ exec("rev-parse --is-shallow-repository", true)
puts "Last 5 commits for #{branch}"
- exec("branch -v")
- exec("--no-pager log -n 5")
+ exec("branch -v", true)
+ exec("--no-pager log -n 5", true)
depth = 0
success =
(3..6).any? do |factor|
depth += Math.exp(factor).to_i
@@ -114,9 +114,10 @@
git_fetch_branch_to_depth(branch, depth)
commit_exists?(commitish)
end
+ puts "success=#{success}"
return if success
git_in_depth_fetch
raise_if_we_cannot_find_the_commit(commitish) if commit_not_exists?(commitish)
end