Re: [PATCH 1/3] for-each-ref: let upstream/push optionally report the remote name

2017-10-05 Thread Johannes Schindelin
Hi Junio, On Wed, 4 Oct 2017, Junio C Hamano wrote: > Johannes Schindelin writes: > > > This patch offers the new suffix :remote for the upstream and for the > > push atoms, allowing to show exactly that. > > Has the design changed since this description and

Re: [PATCH 1/3] for-each-ref: let upstream/push optionally report the remote name

2017-10-04 Thread Junio C Hamano
Junio C Hamano writes: >> +} else if (atom->u.remote_ref.option == RR_REMOTE_NAME) { >> +int explicit; >> +const char *remote = starts_with(atom->name, "push") ? >> +pushremote_for_branch(branch, ) : >> +

Re: [PATCH 1/3] for-each-ref: let upstream/push optionally report the remote name

2017-10-04 Thread Junio C Hamano
Johannes Schindelin writes: > This patch offers the new suffix :remote for the upstream and for the > push atoms, allowing to show exactly that. Has the design changed since this description and examples were written? The documentation talks about ":remote-name". I

[PATCH 1/3] for-each-ref: let upstream/push optionally report the remote name

2017-10-02 Thread Johannes Schindelin
There are times when e.g. scripts want to know not only the name of the upstream branch on the remote repository, but also the name of the remote. This patch offers the new suffix :remote for the upstream and for the push atoms, allowing to show exactly that. Example: $ cat .git/config