filetype.nvim icon indicating copy to clipboard operation
filetype.nvim copied to clipboard

Not all .lock files are toml, only Cargo.lock

Open technicalpickles opened this issue 3 years ago • 0 comments

I was setting up vim-bundler and was struggling to figure out why it kept treating my Gemfile.lock as toml, even though the package includes its own syntax and filetype. I filed https://github.com/tpope/vim-bundler/issues/55 about it.

After some digging, it lead me to https://github.com/nathom/filetype.nvim/blob/b522628a45a17d58fc0073ffd64f9dc9530a8027/lua/filetype/mappings/extensions.lua#L304

Compare this to filetypes.nvim:

au BufNewFile,BufRead Cargo.lock,*/.cargo/config,*/.cargo/credentials	setf toml

I disabled filetype.nvim, and it started working.

technicalpickles avatar Jul 18 '22 16:07 technicalpickles