From 60ea3e6d25c6ec6e1ed659b2e9ba49b91c911424 Mon Sep 17 00:00:00 2001 From: Ori Bernstein Date: Sat, 21 Dec 2024 22:40:27 +0000 Subject: [PATCH] git/pull: only show commit summary after updating branches this makes human error somewhat harder in noscroll windows. --- sys/src/cmd/git/pull | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/sys/src/cmd/git/pull b/sys/src/cmd/git/pull index 10fbf626b..ebc119020 100755 --- a/sys/src/cmd/git/pull +++ b/sys/src/cmd/git/pull @@ -63,10 +63,15 @@ if(! ~ `{git/query HEAD $remote @} `{git/query HEAD}){ } exit diverged } + +oldcommit=`{git/query $local} +newcommit=`{git/query $remote} +echo $remote':' $oldcommit '=>' `$newcommit +git/branch -mnb $remote $local + # The remote is directly ahead of the local, and we have # no local commits that need merging. if(~ $#quiet 0) - git/log -s -e $local'..'$remote -echo $remote':' `{git/query $local} '=>' `{git/query $remote} -git/branch -mnb $remote $local + git/log -s -e $oldcommit'..'$newcommit + exit ''