repo: run launcher with existing python3 program
Debian is deleting /usr/bin/python by default, so re-use the existing
python3 interp that our wrapper was invoked with.
Bug: 1182059
Test: `./repo` still works w/out /usr/bin/python
Change-Id: I1806f2ae2f8c6fe8b5f5a95fd2e50735d6e3196a
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2715994
Reviewed-by: Michael Mortensen <mmortensen@google.com>
Commit-Queue: Mike Frysinger <vapier@chromium.org>
diff --git a/repo b/repo
index ea38074..560ec8d 100755
--- a/repo
+++ b/repo
@@ -48,7 +48,7 @@
if argv and argv[0] == 'sync':
_UpdateDepotTools()
- os.execv(str(REPO), [sys.argv[0]] + argv)
+ os.execv(sys.executable, [sys.executable, str(REPO)] + argv)
if __name__ == '__main__':