Re: Triangular workflow
- From
D. Ben Knoble <ben.knoble@gmail.com>
- Date
- Jan 14, 2026, 02:22 UTC
- Message-ID
- <CALnO6CAnfmDfCFJY55J81TTeRCYqeHq=dVapeanF0d0Z_yg=tw@mail.gmail.com>
- In-Reply-To
- <20260113230107.16728-1-haraldnordgren@gmail.com>
On Tue, Jan 13, 2026 at 6:01 PM Harald Nordgren <haraldnordgren@gmail.com> wrote:
Show 13 quoted lines
> > Hi Jeff! > > I'm very happy that your responded respectfully despite me basically > saying that you were using Git wrong. It's nice to see how some of the pros > do it! > > I'm wondering if since you are scripting this anyway, if you really need a > push branch at all? Can't you just as easily switch to doing this in the > script: > > git config push.default upstream > git push github jk/some-topic
The script is doing the "moral equivalent of" "git push -f github refs/heads/jk/*", so I'm not sure I follow the suggestion here.
Show 13 quoted lines
> As a note, before I started working on this feature, I don't realize > that there was such a thing as a push branch (i.e. something different from > the tracking branch). So I had the habit of checking out and pushing like > this: > > git branch --set-upstream-to upstream/master > git push origin $(git rev-parse --abbrev-ref HEAD) > > I worked really well for me. The only issue was missing the status info > from my own branch -- which is why I started writing this feature. > > > Harald
My workflow is different from Peff's, but it is similar along at least one line: it's really convenient to have "git push" with no further arguments (only possibly flags) to push my branch to a remote mirror.
-- D. Ben Knoble