-
Ravi Mistry authored
If the new flag "--download-topics" is specified with a "--patch-ref" then: * Finds the topic of the Gerrit change. * Finds all open changes in the same repo as the Gerrit change. * Cherrypicks all changes locally. This functionality can be used by developers and bots to apply all changes with the same topic in the checkout to be tested at the same time (similar to how Android's TreeHugger handles topics). Tested by: * Running the new unit test with `python gclient_scm_test.py GerritChangesTest.testDownloadsTopics` from the `tests/` directory. * Running an end-to-end test with `DEPOT_TOOLS_UPDATE=0 gclient sync --patch-ref "skia@d831da5b8ac2d257c5b0cf2ec6645a148f05e662:refs/changes/17/505217/2" --download-topics` in a skia checkout. Bug: chromium:1298922 Change-Id: Ieace5e27fbc9c5d0ea90a037bf80a95062c1b164 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3444003Reviewed-by: Josip Sokcevic <sokcevic@google.com> Commit-Queue: Ravi Mistry <rmistry@chromium.org>
0f13273f