Re: What's cooking in git.git (Apr 2020, #01; Wed, 15)
- From
- Damien Robert <damien.olivier.robert@gmail.com>
- Date
- Apr 16, 2020, 23:05 UTC
- Message-ID
- <20200416230554.bhk2yfycjwjpxggy@doriath>
- In-Reply-To
- <20200416224708.zr4dlrz4hpaqsz2s@doriath>
From Damien Robert, Fri 17 Apr 2020 at 00:47:11 (+0200) :
> The triangular workflow patch is not quite correct in the sense that it > does not handle (yet) all cases
Here were the two reasons for the RFC of this patch e3165570dfca690ea1a71518799153f6350777ae
- in is_workflow_triangular I compute the fetch and push remote. But the push remote is computed again in branch_get_remote_ref. So we redo an already done computation.
- Also in struct remote *fetch_remote = remote_get(remote_for_branch(branch, NULL)); I don't check the value of *explicit.
This means that I get the fallback of 'origin' if no remote is specified. So if I set a pushRemote="foobar" but no remote, then remote.c will consider we are in a triangular workflow but git push will not.