You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
highlight.js is currently being used by GitLab for syntax highlighting purposes. My team is running into issues with syntax highlighting in MATLAB files. Could this possibly be fixed?
Here's an example:
In particular, comments in MATLAB (indicated by a % sign) appear to be ignored, and it's currently failing to detect the end of a string, leading to it highlighting all the following lines as well.
It is not a bug in Matlab highlighting, but rather a mis-detected language. As noted in the downstream issue you referenced, GitLab currently uses file extensions to determine language for highlighting, and the extension ".m" is currently mapped to Objective C in highlight.js. Switching to auto detection in GitLab should fix this particular case. However auto detection is just another kind of heuristics, and it won't always work correctly either. Still, it's better than trying to highlight Matlab files as Objective C indefinitely.
What we could do, though, is to remove "m" as an alias for Objective C, because it appears to be a pretty widely used extension.
highlight.js is currently being used by GitLab for syntax highlighting purposes. My team is running into issues with syntax highlighting in MATLAB files. Could this possibly be fixed?
Here's an example:
In particular, comments in MATLAB (indicated by a % sign) appear to be ignored, and it's currently failing to detect the end of a string, leading to it highlighting all the following lines as well.
This is not a GitLab issue according to the community.
The text was updated successfully, but these errors were encountered: