This change adds submodule support to roll-dep. Currently, roll-dep command takes a set of dependencies, revisions to roll them to (or origin/HEAD by default), uses `gclient getdep` to get the current rev, and `gclient setdep` to update the DEPS file.
With this change, if `.gitmodules` is present, roll-dep uses it instead to find the current revision and also updates the submodule's pinned revision. This also keeps the existing flow for updating DEPS file for interperability.
Fixed: 1406766
Change-Id: I56b6e268cc1a7c49dabc2dc39fef2d820d2690c7
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/4167341
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org>
Commit-Queue: Aravind Vasudevan <aravindvasudev@google.com>