On an old 10.12 MBP, srt files are displaying as text in Quicklook. But on another laptop under 10.15, they're not: I have the VLC file icon and can"t get a way to display the file content as text in QL. On both computers, all the SRT files are set to default open with VLC.
Tried to trace preview with qlmanage -p file.srt
, which only gives this for the new one:
2020-11-27 15:04:28.046 qlmanage[11094:574062] *** CFMessagePort: bootstrap_register(): failed 1100 (0x44c) 'Permission denied', port = 0x6a03, name = 'com.apple.coredrag'
See /usr/include/servers/bootstrap_defs.h for the error codes.
2020-11-27 15:04:28.158 qlmanage[11094:574062] *** CFMessagePort: bootstrap_register(): failed 1100 (0x44c) 'Permission denied', port = 0xb01f, name = 'com.apple.tsm.portname'
See /usr/include/servers/bootstrap_defs.h for the error codes.
But says it uses TextMate's QL plugin on the old one. TextMate is installed on both computers.
So I tried mdls file.srt
on the old one:
...
kMDItemContentType = "org.videolan.srt"
kMDItemContentTypeTree = (
"org.videolan.srt",
"public.item",
"public.text",
"org.videolan.srt",
"public.data",
"public.content",
"public.plain-text"
)
...
kMDItemKind = "Subrip Subtitle File"
...
while on the new one:
...
kMDItemContentType = "dyn.ah62d4rv4ge81g6xy"
kMDItemContentTypeTree = (
"public.item",
"dyn.ah62d4rv4ge81g6xy",
"public.data"
)
...
kMDItemKind = "Subrip Subtitle File"
I tried to find how to add this public.plain-text
entry on the new one, and tried
defaults write com.apple.LaunchServices LSHandlers -array-add '<dict><key>LSHandlerContentType</key><string>org.videolan.srt</string><key>LSHandlerRoleAll</key><string>org.videolan.vlc</string><key>LSHandlerIgnoreCreator</key><true/></dict>'
/System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/LaunchServices.framework/Versions/A/Support/lsregister -kill -r -domain local -domain system -domain user
But nothing works.
Kind of trivia but very annoying not to know how to change this. Any clue?