Re: [PATCH/RFC] config: Give error message when not changing a multivar
- From
Jeff King <peff@peff.net>
- Date
- May 17, 2011, 14:07 UTC
- Message-ID
- <20110517140725.GA17193@sigill.intra.peff.net>
- In-Reply-To
- <4DD28014.4090505@drmicha.warpmail.net>
On Tue, May 17, 2011 at 04:03:00PM +0200, Michael J Gruber wrote:
Show 7 quoted lines
> >> warning: remote.repoor.push has multiple values > >> error: Use a regexp, --add or --set-all to change remote.repoor.push. > [...] > OK, makes sense, I just wanted to request for comments early enough - > someone might think we should remove the warning from the present site > and make all callers deal with the return codes. But I don't think it's > worth it, and we have other places where we warn first, then error out.
You could maybe make it a little more clear what is going on with:
warning: remote.repoor.push has multiple values
error: cannot overwrite multiple values with a single value
Use a regexp, --add, or --set-all to change remote.repoor.pushThen the error stands on its own, but the warning is not a bad thing to have, also.
-Peff