From dfa51ea88bd3cc6d0199cb743b6ceb4952cc3fc3 Mon Sep 17 00:00:00 2001 From: Anne Redulla Date: Tue, 10 Dec 2024 07:28:23 +0000 Subject: [PATCH] [win-bootstrap] Include manual instructions in git bootstrap warning Bug: b/382395049 Change-Id: I61aab102f68b2a30d1095e89d2d3b9ee46aa8480 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6072989 Commit-Queue: Anne Redulla Reviewed-by: Josip Sokcevic --- bootstrap/bootstrap.py | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/bootstrap/bootstrap.py b/bootstrap/bootstrap.py index 68441956d..01a1b7acf 100644 --- a/bootstrap/bootstrap.py +++ b/bootstrap/bootstrap.py @@ -415,13 +415,21 @@ def _win_git_bootstrap_config(): if allow_global not in ('true', '1', 'yes', 'on'): lines = [ - 'depot_tools would like to update your global Git config', - 'to have the optimal settings for Chromium development.', + 'depot_tools recommends setting the following for', + 'optimal Chromium development:', + '', + ] + [ + f'$ git config --global {k} {GIT_GLOBAL_CONFIG.get(k)}' + for k in mismatching_keys + ] + [ + '', + 'You can silence this message by setting these recommended values.', + '', 'You can allow depot_tools to automatically update your global', 'Git config to recommended settings by running:', f'$ git config --global {allow_global_key} true', '', - 'To suppress this warning:', + 'To suppress this warning and silence future recommendations, run:', f'$ git config --global {allow_global_key} false', ]