gpush: reuse trees more aggressively


handle the case of rebasing the same diff to the same base tree. this
occurs when ancestors are amended without tree modification, are split
or joined, or hunks are moved between them.

Change-Id: I75aaea557884658a4a4dcad7502360b61f590a9a
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
commit66bbb6e430b85d14fda97532a605ff59d8f21e17
parent21d6a4925f883045d6750e7f50bbd566bbca3438
authorOswald Buddenhagen <oswald.buddenhagen@gmx.de>
committerOswald Buddenhagen <oswald.buddenhagen@gmx.de>
commit timeTue, 9 Jan 2024 16:34:58 +0000