readRemoteDefaultBranchCommit
Reads the commit SHA of the remote tracking branch for the current checkout from the local git database — no external process required.
Resolution order:
The current branch's configured upstream tracking ref (e.g.
origin/product-releasewhen on a branch tracking that remote ref).origin/masterorigin/main
This gives the last commit that exists on the remote, which is the effective "parent" from which local analysis commits diverge.
Checks both loose ref files and packed-refs. Returns null when no remote tracking ref can be resolved.