Sublime Forum

"5 character bug" breaks integration with Sublime Text

#1

I edit a file in Sublime Text having the git path:

topfolder/subfolder/myfile.php

I right click whilst editing the file and can choose File History or Line History.

This opens Sublime Merge with the search command:

file:lder/subfolder/myfile.php

or

file:"lder/subfolder/myfile.php" line:1-1

As you can see, the first 5 characters of the file path have been removed, so the search fails, breaking the integration.

This happens for every file in every folder, always the first 5 characters are removed.

Anyone else seeing this?

0 Likes

#2

It just so happens that file: is a string of 5 characters. But maybe that’s a coincidence.

0 Likes

#3

What versions are you using? What platform?

0 Likes

#4

ST 4113 and SM 2059. It bugs me regularly, too.

I mainly see this when working with Default Packages.

It seems to be related with symlinks and worktrees somehow. Worst if a syntax folder is checked out in a dedicated worktree and symlinked into ST’s packages folder.

I have one Packages repo.

The syntaxes I work on are managed in dedicated worktrees next to that main repo, only required syntax folder being checked out via git sparse checkout. This folder is then symlinked in Packages folder to be able to run syntax_tests etc.

I either see /Packages/... in SM’s path then or just trunkated ages/....

0 Likes

#5

ST 4113, SM 2059, Mac M1

I am not using symlinks however the Git repository was created external to the files using the gitdir: /path/to/repo.git option.

0 Likes

#6

I don’t see any issue with File/Line history on my end (windows 10, stable channel, build 2059), but thank you for pointing out those context commands exist. I had no idea!

0 Likes