Thread (1 message) 1 message, 1 author, 2016-06-15

Re: bash_completion outside repo

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:47:23

Junio C Hamano [off-list ref] writes:
Jeff King [off-list ref] writes:
quoted
I think something like that needs to "belong" to the diff code itself. I
guess in the case of "diff", we could check all diff-related config at
diff setup time.
Not necessarily.  You do not want to care about color configuration if you are
doing diff --raw for example.  The one that first uses the color variable
should be able to notice the breakage, no?
quoted
But what about something used in several places, like
core.quotepath?
Exactly the same way I checked what codepaths needed to fix for the
autosetupmerge stuff.  core.quotepath internally sets quote_path_fully,
and the sole user of quote_path_fully is sq_must_quote() which is only
used by next_quote_pos().  So you can have your check very isolated.
Note that I was _not_ defending the approach my illustration took.  I
merely was pointing out that core.quotepath and diff.color are _not_
valid counterexamples to it.

A better counter-proposal would be made something along this line:

	Currently, core.frotz and nitfol.rezrov both map internally to a
	variable xyzzy, so config parser could set xyzzy = INVALID_INFOCOM
        but the user of xyzzy cannot report which configuration variable
	caused the error with your illustration scheme.  Here is my
	attempt to solve this issue.

	...patch follows...

And I am sure we will be able to find such examples that my illustration
patch is not _exactly_ the best approach to solve pretty easily around
remote.*.* and branch.*.* variables.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help