Jeff King <peff@xxxxxxxx> writes: > The problem is running test-config inside of a git alias. The > bin-wrappers will set the exec-path to the root-level of git's build > directory, which the git binary will then stick at the front of the > $PATH. I was wondering why exec-path does not point at bin-wrappers in the first place. A wrapper script needs to know where the real thing lives in order to "exec" (or "exec gdb") anyway, and it hardcodes the path to it. It happens to use GIT_EXEC_PATH to shorten the hardcoded path it uses when it does "exec", but it does not have to. Wouldn't we want to see "git" use any of these wrapped ones when it invokes a non-builtin subcommand when it does so normally, honoring GIT_EXEC_PATH? Pointing GIT_EXEC_PATH at the top-level means that wrappers are bypassed for such an invocation (if what is run happens to have executable at the top-level), and possibly a totally wrong thing is run (when we start generating the binaries in different directories, which is what we are seeing here). > So the simplest solution really is: don't do that. The only debate > in my mind is whether this is rare enough that it won't bite > somebody again in the future, or if we should look into a solution > that makes this Just Work. I think it was you who alluded to revamping the test framework along the lines of preparing a "test installation" (aka "make install" with DESTDIR set to somewhere) and making bin-wrappers to point into that installation (or if we are testing an installed Git that may be different from what we have source for, that final installed location). An installed version of Git will not have test-* helpers so they need to come from a freshly built source tree, not from "test installation" or "installed Git". There may be other details that need to be worked out, but as a longer term direction that may not be a bad idea. -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html