Index: tools/auto_bisect/source_control.py |
diff --git a/tools/auto_bisect/source_control.py b/tools/auto_bisect/source_control.py |
index ea6bde8bafb0338773489371a3ecdf101154cfcc..a6a30cc401cb820250dc3720b6179102156b3113 100644 |
--- a/tools/auto_bisect/source_control.py |
+++ b/tools/auto_bisect/source_control.py |
@@ -114,7 +114,7 @@ class GitSourceControl(SourceControl): |
def ResolveToRevision(self, revision_to_check, depot, depot_deps_dict, |
search, cwd=None): |
- """If an SVN revision is supplied, try to resolve it to a git SHA1. |
+ """Tries to resolve an SVN revision or commit position to a git SHA1. |
Args: |
revision_to_check: The user supplied revision string that may need to be |
@@ -151,8 +151,9 @@ class GitSourceControl(SourceControl): |
for i in search_range: |
svn_pattern = 'git-svn-id: %s@%d' % (depot_svn, i) |
+ commit_position_pattern = 'Cr-Commit-Position: .*@{#%d}' % i |
cmd = ['log', '--format=%H', '-1', '--grep', svn_pattern, |
- 'origin/master'] |
+ '--grep', commit_position_pattern, 'origin/master'] |
(log_output, return_code) = bisect_utils.RunGit(cmd, cwd=cwd) |