Skip to content

Commit 8f55e42

Browse files
Merge pull request #27538 from varungandhi-apple/vg-update-update-checkout
Remove special case for swift-ci in update-checkout.
2 parents 5ce10d1 + 76aeffc commit 8f55e42

File tree

1 file changed

+3
-12
lines changed

1 file changed

+3
-12
lines changed

utils/update_checkout/update_checkout/update_checkout.py

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -40,18 +40,9 @@ def confirm_tag_in_repo(tag, repo_name):
4040

4141

4242
def find_rev_by_timestamp(timestamp, repo_name, refspec):
43-
base_args = ["git", "log", "-1", "--format=%H",
44-
'--before=' + timestamp]
45-
# On repos with regular batch-automerges from swift-ci -- namely clang,
46-
# llvm and lldb -- prefer the most-recent change _made by swift-ci_
47-
# before the timestamp, falling back to most-recent in general if there
48-
# is none by swift-ci.
49-
if repo_name in ["llvm", "clang", "lldb"]:
50-
rev = shell.capture(base_args +
51-
['--author', 'swift-ci', refspec]).strip()
52-
if rev:
53-
return rev
54-
rev = shell.capture(base_args + [refspec]).strip()
43+
args = ["git", "log", "-1", "--format=%H", "--first-parent",
44+
'--before=' + timestamp, refspec]
45+
rev = shell.capture(args).strip()
5546
if rev:
5647
return rev
5748
else:

0 commit comments

Comments
 (0)