Re: [PATCH 1/4] push options: {pre,post}-receive hook learns about push options
- From
Stefan Beller <sbeller@google.com>
- Date
- Jul 1, 2016, 19:31 UTC
- Message-ID
- <CAGZ79kYB8jej6VMsBACvAG_B-PyWAbe+tBQLXmF2nL8P+zX1KA@mail.gmail.com>
- In-Reply-To
- <xmqqr3bdxirw.fsf@gitster.mtv.corp.google.com>
On Fri, Jul 1, 2016 at 12:25 PM, Junio C Hamano <gitster@pobox.com> wrote:
Show 12 quoted lines
> Jeff King <peff@peff.net> writes: > >> Compare to: >> >> if test "$GIT_PUSH_VAR_force" = true >> ... > > OK. As this is a new feature, I guess it is not too bad if we tell > users that they cannot have duplicate keys in their <key,val> data > they ask Git to transport. They can do the key1=val1 key2=val2 > numbering themselves if that is really needed. >
The original use case for us was to send out email on your behalf, so git push -o CC=user1@domain -o CC=user2@domain would not work well with this backend approach as the client would already yell at us for duplicate keys.
Instead that has to be `git push -o CC=user1@domain,user2@domain and we do need to parse the email addresses apart ourselves.
So currently I'd favor the _COUNT thing and we deliver a reasonable _COUNT -> key/value parser/translator in the example hook.