Closed
Description
The problem is slightly mentioned in #865.
Let's consider the following example:
git init foo
cd ./foo
echo a > a
git add a
git commit -a -m 'Add a'
echo "foo" > špatně.txt
git add špatně.txt
git commit -a -m Add
In [4]: Repo('.').commit().diff('HEAD~')[0].a_path
Out[4]: '"\\305\\241patn\\304\\233.txt"'
Unless one uses git config --global core.quotepath false
, the file name is quoted and I don't see a simple solution how to decode it to unicode? One can use -z
option that can resolve the problem:
git diff HEAD~ --raw -z | cat
:000000 100644 0000000 257cc56 Ašpatně.txt