ugit
ugit copied to clipboard
git status doesn't show paths with escaped characters
Hi,
Great tool!
There's one minor issue.
git status for an example file name with the ü character.txt would return:
file name with the \303\274 character.txt
for git status -z:
file name with the ü character.txt
but unfortunately ugit skips the file.
Please fix me in spare time ;).
@mkielek thanks for reporting this. I think I've seen some issues with git and multibyte characters before. Do you have a repo you can point me to that helps reproduce this issue?
Unfortunately I can't point you to the repo as we don't use ugit. I was only experimenting with this. But you can use the following repro steps:
git init
New-Item -Path "file name with the ü character.txt"
git status
# see output 1 below
git status -z
# see output 2 below
Install-Module ugit -Scope CurrentUser
Import-Module ugit -Force -PassThru
git status
# see output 3 below
# output 1
On branch master
No commits yet
Untracked files:
(use "git add <file>..." to include in what will be committed)
"file name with the \303\274 character.txt"
nothing added to commit but untracked files present (use "git add" to track)
# output 2
?? file name with the ü character.txt
# output 3
GitRoot: <root path>
On Branch: master
Nothing to commit, working tree clean
$PSVersionTable.PSVersion: 7.3.6
git -v: 2.37.2.windows.2
[console]::OutputEncoding.CodePage: 850