kokoro: update submodules after rebasing

In case the rebase brought in a commit that updated the submodules, we
should update them after the rebase instead of before. Otherwise the
submodules will be out of date compared to the source.

BUG=None
TEST=None

Change-Id: I398755abc76e9e6672c71ff1fe358a7c201c09fb
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosvm/+/3403133
Reviewed-by: Dennis Kempin <denniskempin@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Commit-Queue: Daniel Verkamp <dverkamp@chromium.org>
This commit is contained in:
Daniel Verkamp 2022-01-19 17:08:16 -08:00 committed by Commit Bot
parent 81ae6f366a
commit 44495f3a8e

View file

@ -28,9 +28,6 @@ setup_source() {
cd "${KOKORO_ARTIFACTS_DIR}/git/crosvm"
echo "Fetching Submodules..."
git submodule update --init
echo "Rebasing changes to ToT"
# We cannot use the original origin that kokoro used, as we no longer have
# access the GoB host via rpc://.
@ -42,6 +39,9 @@ setup_source() {
# us from rebasing the changes.
git checkout -f
git rebase origin/main
echo "Fetching Submodules..."
git submodule update --init
}
cleanup() {