Fix file stashing with external diff tool

When git is configured to use an external diff tool to show diffs
(eg. 'git config diff.external mytool'), the stashing unstaged files
will create an empty file that can't be recovered.

Some modifications are permanently lost...

Just disable the ext-diff of git diff to avoid any issue.

Change-Id: I10a57ac2acbcb1f7219455f1958efd50d8452d6a
This commit is contained in:
Sebastien Chemin 2016-09-09 16:19:53 +02:00
parent 9c6484b94f
commit 5206ce2448

View file

@ -23,7 +23,7 @@ def staged_files_only(cmd_runner):
retcode, diff_stdout_binary, _ = cmd_runner.run(
[
'git', 'diff', '--ignore-submodules', '--binary', '--exit-code',
'--no-color',
'--no-color', '--no-ext-diff',
],
retcode=None,
encoding=None,