Mercurial > vim
comparison runtime/filetype.vim @ 34840:928f698878ea v9.1.0289
patch 9.1.0289: filetype: some TeX files are not recognized
Commit: https://github.com/vim/vim/commit/61ee833a504ae73bc6b3e2527a81582263f02afd
Author: Wu, Zhenyu <wuzhenyu@ustc.edu>
Date: Tue Apr 9 22:09:30 2024 +0200
patch 9.1.0289: filetype: some TeX files are not recognized
Problem: filetype: some TeX files are not recognized
Solution: Add more patterns for TeX files and inspect
a few more files for being TeX files
(Wu, Zhenyu)
closes: #14456
Signed-off-by: Wu, Zhenyu <wuzhenyu@ustc.edu>
Signed-off-by: Christian Brabandt <cb@256bit.org>
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Tue, 09 Apr 2024 22:15:04 +0200 |
parents | 207487eb4f4e |
children | 87c0152e321c |
comparison
equal
deleted
inserted
replaced
34839:0a374b6f92fb | 34840:928f698878ea |
---|---|
303 au BufNewFile,BufRead *.csdl setf csdl | 303 au BufNewFile,BufRead *.csdl setf csdl |
304 | 304 |
305 " Cabal | 305 " Cabal |
306 au BufNewFile,BufRead *.cabal setf cabal | 306 au BufNewFile,BufRead *.cabal setf cabal |
307 | 307 |
308 " Cdrdao TOC | 308 " Cdrdao TOC or LaTeX \tableofcontents files |
309 au BufNewFile,BufRead *.toc setf cdrtoc | 309 au BufNewFile,BufRead *.toc |
310 \ if getline(1) =~# '\\contentsline' |setf tex|else|setf cdrtoc|endif | |
310 | 311 |
311 " Cdrdao config | 312 " Cdrdao config |
312 au BufNewFile,BufRead */etc/cdrdao.conf,*/etc/defaults/cdrdao,*/etc/default/cdrdao,.cdrdao setf cdrdaoconf | 313 au BufNewFile,BufRead */etc/cdrdao.conf,*/etc/defaults/cdrdao,*/etc/default/cdrdao,.cdrdao setf cdrdaoconf |
313 | 314 |
314 " Cfengine | 315 " Cfengine |
1256 | 1257 |
1257 " Logtalk | 1258 " Logtalk |
1258 au BufNewFile,BufRead *.lgt setf logtalk | 1259 au BufNewFile,BufRead *.lgt setf logtalk |
1259 | 1260 |
1260 " LOTOS | 1261 " LOTOS |
1261 au BufNewFile,BufRead *.lot,*.lotos setf lotos | 1262 au BufNewFile,BufRead *.lotos setf lotos |
1263 | |
1264 " LOTOS or LaTeX \listoftables files | |
1265 au BufNewFile,BufRead *.lot | |
1266 \ if getline(1) =~# '\\contentsline' |setf tex|else|setf lotos|endif | |
1262 | 1267 |
1263 " Lout (also: *.lt) | 1268 " Lout (also: *.lt) |
1264 au BufNewFile,BufRead *.lou,*.lout setf lout | 1269 au BufNewFile,BufRead *.lou,*.lout setf lout |
1265 | 1270 |
1266 " Lua, Texlua | 1271 " Lua, Texlua |
2310 au BufRead,BufNewFile *.tfvars setf terraform-vars | 2315 au BufRead,BufNewFile *.tfvars setf terraform-vars |
2311 | 2316 |
2312 " TeX | 2317 " TeX |
2313 au BufNewFile,BufRead *.latex,*.sty,*.dtx,*.ltx,*.bbl setf tex | 2318 au BufNewFile,BufRead *.latex,*.sty,*.dtx,*.ltx,*.bbl setf tex |
2314 au BufNewFile,BufRead *.tex call dist#ft#FTtex() | 2319 au BufNewFile,BufRead *.tex call dist#ft#FTtex() |
2320 | |
2321 " LaTeX packages use LaTeX as their configuration, such as: | |
2322 " ~/.texlive/texmf-config/tex/latex/hyperref/hyperref.cfg | |
2323 " ~/.texlive/texmf-config/tex/latex/docstrip/docstrip.cfg | |
2324 au BufNewFile,BufRead */tex/latex/**.cfg setf tex | |
2325 | |
2326 " LaTeX packages will generate some medium LaTeX files during compiling | |
2327 " They should be ignored by .gitignore https://github.com/github/gitignore/blob/main/TeX.gitignore | |
2328 " Sometime we need to view its content for debugging | |
2329 au BufNewFile,BufRead *.{pgf,nlo,nls,out,thm,eps_tex,pygtex,pygstyle,clo,aux,brf,ind,lof,loe,nav,vrb,ins,tikz,bbx,cbx,beamer} setf tex | |
2315 | 2330 |
2316 " ConTeXt | 2331 " ConTeXt |
2317 au BufNewFile,BufRead *.mkii,*.mkiv,*.mkvi,*.mkxl,*.mklx setf context | 2332 au BufNewFile,BufRead *.mkii,*.mkiv,*.mkvi,*.mkxl,*.mklx setf context |
2318 | 2333 |
2319 " Texinfo | 2334 " Texinfo |