The git status builtin includes a calculation for how far the local ref is ahead or behind the remote tracking branch. This check can be expensive, so we already have a --[no-]ahead-behind command-line option. This series adds two bits of functionality to the feature: 1. Add a new status.aheadBehind config setting. 2. Add a new advice.statusAheadBehind config setting associated with a warning that suggests status.aheadBehind when the calculation takes a long time. We have been running with these commits in microsoft/git for a while now. The only change I made in adapting Jeff's commits was to add the advice config documentation. The status.aheadBehind config setting is a candidate to be added to the proposed "large repo" meta-config setting previously discussed [1]. I'm putting this out for independent review as it is much smaller compared to the potential of that series. Thanks, -Stolee [1] https://public-inbox.org/git/pull.254.git.gitgitgadget@xxxxxxxxx/ Jeff Hostetler (3): status: add status.aheadbehind setting status: warn when a/b calculation takes too long status: ignore status.aheadbehind in porcelain formats Documentation/config/advice.txt | 6 ++++++ Documentation/config/status.txt | 5 +++++ advice.c | 2 ++ advice.h | 1 + builtin/commit.c | 19 ++++++++++++++++++- t/t6040-tracking-info.sh | 31 +++++++++++++++++++++++++++++++ t/t7064-wtstatus-pv2.sh | 8 ++++++++ wt-status.c | 17 +++++++++++++++++ 8 files changed, 88 insertions(+), 1 deletion(-) base-commit: b697d92f56511e804b8ba20ccbe7bdc85dc66810 Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-272%2Fderrickstolee%2Fstatus-ahead-behind-v1 Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-272/derrickstolee/status-ahead-behind-v1 Pull-Request: https://github.com/gitgitgadget/git/pull/272 -- gitgitgadget