--
--
To unsubscribe, email repo-discuss...@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en
---
You received this message because you are subscribed to the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to repo-discuss...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
https://gerrit-review.googlesource.com/42652
tl;dr: Git won't modify the protocol to let us pass more data. Define
a new refs/@ prefix that uses options embedded in the reference
specification:
refs/@master/r=alice
refs/@master/r=alice/topic=bug42
refs/@master/r=alice/cc=bob,charlie
My goal is to let `repo upload` pass its --re/--cc flags to Gerrit
over HTTP where we can't rely on the SSH parser currently used. Its a
bonus if we can make this definition be "extensible" in the same way
that command line options are least named and unique.
I considered several alternatives:
refs/for/master/bug42%r=alice,cc=bob,charlie
# splitting on , confuses something like cc
refs/for/master/bug42%{r=alice}{cc=bob,charlie}
# fixes the comma issue, but is maybe too ugly
ref/for/master/bug42/r=alice,cc=bob,charlie
# maybe too ambiguous to parse the options?
refs/for/master/bug42/r=alice/cc=bob,charlie
# also a bit ugly to parse
Something I haven't considered but we may need to is allowing plugins
to add their own options here. Specifically a commit validator plugin
might want to let the user say "ignore the validator" e.g. in a case
where the user is importing a commit done by someone else and the
validator shouldn't reject its style.
I’m probably missing something obvious but can you explain why this is too hard to pass?
refs/for/master/bug42/r=alice/cc=bob,charlie
# also a bit ugly to parse
Isn’t it just a case of finding the first path segment with an equals sign in, anything before that is part of the ref name (and matched as it currently is), all segments after this must have an equals sign in and are treated as key-value pairs?
This has the advantage that the push syntax stays fundamentally the same with just some additional optional extensions at the end.
I assume that ‘?’ is not a permitted character so we can’t just treat it as a URI:
refs/for/master/bug42?r=alice&cc=bob,charlie
Thomas
--
--
--
To unsubscribe, email repo-discuss...@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en
---
You received this message because you are subscribed to the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to repo-discuss...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.