Skip to content

Conversation

@graydon
Copy link
Contributor

@graydon graydon commented Feb 16, 2017

This adds a new command line flag to update-checkout to enable syncing adjacent
repositories to the swift repo by commit timestamp, as one needs to do when
bisecting swift history.

To use it, one just runs utils/update-checkout --match-timestamp; it extracts the
current checkout's timestamp and then moves the adjacent repositories to the latest
checkout they have before that timestamp.

If there is a most-recent commit before the target timestamp made by swift-ci, it will
prefer that over a more-recent commit not-by-swift-ci; this is necessary to land on a
revision that actually represents a valid merged state, rather than a more-recent
merge input on an upstream branch (as happens every few minutes in the llvm and clang
repos).

@jrose-apple
Copy link
Contributor

Rather than look at the most-recent commit by swift-ci, you should be able to look for the most recent mainline commit. I don't remember the git magic for that offhand, though.

@graydon
Copy link
Contributor Author

graydon commented Feb 16, 2017

(Conferred with Jordan on this, he means --first-parent, which is unfortunately not stable enough to rely on in our history, so merging as-is)

@graydon
Copy link
Contributor Author

graydon commented Feb 16, 2017

@swift-ci please smoke test and merge

@gottesmm
Copy link
Contributor

This looks pretty cool

@graydon
Copy link
Contributor Author

graydon commented Feb 17, 2017

@swift-ci please smoke test and merge

@swift-ci swift-ci merged commit 5fb6bb2 into swiftlang:master Feb 17, 2017
@graydon graydon deleted the teach-update-checkout-to-match-current-timestamp branch September 13, 2017 16:42
@AnthonyLatsis AnthonyLatsis added the update-checkout Area → utils: the `update-checkout` script label Sep 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

update-checkout Area → utils: the `update-checkout` script

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants