Introduce find_exe. Use instead of find_in_path for programs.
The behaviour of find_in_path was broken for config options containing
path names, because it always searched the given path, even when not
necessary. The find_exe function is more polite: if the name passed
to it contains a path component, it just returns it.
patchbomb: Defer the import of readline.
If imported at the top of the module, the import appears to succeed,
but raw_input doesn't acquire magic editing fu. I suspect this has
something to do with the newish demandimport code, because the prior
code worked with demandload.
patchbomb: Don't prompt for headers until sure we have revs to export.
The prior behaviour was to always prompt for headers, and only then
bomb out if there were actually no revs to send.
Also check the index file size when deciding whether to reload a revlog.
This should fix some spurious failures from test-clone-pull-corruption
(
issue552).