Open 4rtemis-4rrow opened 2 months ago
this is intresting
⮚ xdg-mime query filetype autopairs.lua
text/plain
⮚ xdg-mime query filetype dashboard.lua
application/javascript
seems like it isn't an issue with ranger, anyone knows what might have caused this?
I don’t know why it happen, but a solution is to add | */javascript
in your scope.sh
, in the handle_mime
function, in the first line of the ## Text
section.
The scope.sh
uses the file
to detect the mime-type of a file and it happens to me as well for lua files. When I changed to xdg-mime
the problem has been resolved for all my lua files (xdg-mime
version is xdg-mime 1.1.3
).
my init.lua file for nvim is showing "Javascript source, ASCII text", however querying it with xdg-mime shows it as text/x-lua, so i dont think it has to do with xdg-mime
Runtime Environment
Current Behavior
when hovering over source code files, in some cases it displays the actual source code in the preview pane, in other cases, it displays "----- File Type Classification -----\nJavaScript source, Unicode text, UTF-8 text", even if both files are the same type, even if none are javascript
Steps to reproduce
no idea why it's happening to begin with, I'm using bat for the preview, and my dotfiles can be found it github.com/4rtemis-4rrow/dotfiles