split: handle partial commit of renames when doing split or record (
issue5723)
When using split or record, using either interface (text or curses), selecting
portions of the file to be committed/recorded did not work; the entire file was
treated as having been selected. This was because the logic for handling partial
application of the patches relies on knowing what files are "new with
modifications" and it doesn't treat "rename destination" as "new".
There was a complicating issue, however. We're relying on the patch header
specifying the copy from/to information, which works as long as the 'copy from'
file is there. In the case of renames, however, the 'rename from' file is *not*
there, so we need to add it back.
Differential Revision: https://phab.mercurial-scm.org/D6768
split: handle partial commit of copies when doing split or record
When using split or record, using either interface (text or curses), selecting
portions of the file to be committed/recorded did not work; the entire file was
treated as having been selected. This appears to be because the logic for
handling partial application of the patches relies on knowing what files are
"new with modifications", and it doesn't treat "copy destination" as "new".
Handling renames correctly is more difficult and will be done in a later patch.
Differential Revision: https://phab.mercurial-scm.org/D6767
py3: use pycompat.sysargv[0] for instead of fsencode(sys.argv[0])
Yuya noted in a recent review that fsencode(sys.argv[0]) could be
incorrect on Windows.
Differential Revision: https://phab.mercurial-scm.org/D6782
httppeer: use context manager when reading temporary bundle to send
Differential Revision: https://phab.mercurial-scm.org/D6784