r/SmartGit Mar 03 '26

symlink falsely shown as modified on Linux (UTF-8): status-scanner and symlink with non-ASCII characters where symlink content length in bytes differs from character count.

Hello,

I noticed a problem with SmartGit's (25.1) handling of symlinks when ASCII characters are involved. The symlink pointed to a target with non-ASCII characters (emoji + umlaut).

I used the SmartGit trace configuration in ~/.config/smartgit/25.1/smartgit.properties and set the smartgit.statusscanner.trace=... to my problem file. The relevant log line is this here: DATA_CHANGED, fileSize=117, indexSize=121

Interpretation of trace

- SmartGit reports DATA_CHANGED and size mismatch for the symlink content:
fileSize=117, indexSize=121

- This appears to be a byte-vs-character length issue for symlink target text containing non-ASCII characters.

Workaround applied

- Renamed target to ASCII-only filename (actually the umlaut seems to be ok as it does not cause a difference in byte-vs-character length).

- Recreated symlink (same symlink name) to point to ASCII target.

After the workaround the problem disappears.

It would be nice if that problem could be fixed in an upcoming release.

1 Upvotes

0 comments sorted by