@@ -786,8 +786,8 @@ local extension = {
786786zut = ' zimbutempl' ,
787787zsh = ' zsh' ,
788788vala = ' vala' ,
789- E = function ()
790- vim .fn [ ' dist#ft#FTe ' ]( )
789+ E = function (path , bufnr )
790+ require ( ' vim.filetype.detect ' ). e ( bufnr )
791791end ,
792792EU = function (path ,bufnr )
793793return require (' vim.filetype.detect' ).euphoria (bufnr )
@@ -804,8 +804,8 @@ local extension = {
804804EXW = function (path ,bufnr )
805805return require (' vim.filetype.detect' ).euphoria (bufnr )
806806end ,
807- PL = function ()
808- vim .fn [ ' dist#ft#FTpl ' ]( )
807+ PL = function (path , bufnr )
808+ require ( ' vim.filetype.detect ' ). pl ( bufnr )
809809end ,
810810R = function (path ,bufnr )
811811require (' vim.filetype.detect' ).r (bufnr )
@@ -816,14 +816,14 @@ local extension = {
816816bas = function (path ,bufnr )
817817require (' vim.filetype.detect' ).bas (bufnr )
818818end ,
819- bi = function ()
820- vim .fn [ ' dist#ft#FTbas ' ]( )
819+ bi = function (path , bufnr )
820+ require ( ' vim.filetype.detect ' ). bas ( bufnr )
821821end ,
822- bm = function ()
823- vim .fn [ ' dist#ft#FTbas ' ]( )
822+ bm = function (path , bufnr )
823+ require ( ' vim.filetype.detect ' ). bas ( bufnr )
824824end ,
825- bash = function ()
826- vim .fn [ ' dist#ft#SetFileTypeSH ' ]( ' bash' )
825+ bash = function (path , bufnr )
826+ require ( ' vim.filetype.detect ' ). sh ( path , bufnr , ' bash' )
827827end ,
828828btm = function (path ,bufnr )
829829return require (' vim.filetype.detect' ).btm (bufnr )
@@ -834,38 +834,38 @@ local extension = {
834834ch = function (path ,bufnr )
835835return require (' vim.filetype.detect' ).change (bufnr )
836836end ,
837- com = function ()
838- vim .fn [ ' dist#ft#BindzoneCheck ' ]( ' dcl' )
837+ com = function (path , bufnr )
838+ require ( ' vim.filetype.detect ' ). bindzone ( bufnr , ' dcl' )
839839end ,
840- cpt = function ()
841- vim .fn [ ' dist#ft#FThtml ' ]( )
840+ cpt = function (path , bufnr )
841+ require ( ' vim.filetype.detect ' ). html ( bufnr )
842842end ,
843- csh = function ()
844- vim .fn [ ' dist#ft#CSH ' ]( )
843+ csh = function (path , bufnr )
844+ require ( ' vim.filetype.detect ' ). csh ( path , bufnr )
845845end ,
846846d = function (path ,bufnr )
847847return require (' vim.filetype.detect' ).dtrace (bufnr )
848848end ,
849- db = function ()
850- vim .fn [ ' dist#ft#BindzoneCheck ' ]( ' ' )
849+ db = function (path , bufnr )
850+ require ( ' vim.filetype.detect ' ). bindzone ( bufnr , ' ' )
851851end ,
852- dtml = function ()
853- vim .fn [ ' dist#ft#FThtml ' ]( )
852+ dtml = function (path , bufnr )
853+ require ( ' vim.filetype.detect ' ). html ( bufnr )
854854end ,
855- e = function ()
856- vim .fn [ ' dist#ft#FTe ' ]( )
855+ e = function (path , bufnr )
856+ require ( ' vim.filetype.detect ' ). e ( bufnr )
857857end ,
858- ebuild = function ()
859- vim .fn [ ' dist#ft#SetFileTypeSH ' ]( ' bash' )
858+ ebuild = function (path , bufnr )
859+ require ( ' vim.filetype.detect ' ). sh ( path , bufnr , ' bash' )
860860end ,
861- eclass = function ()
862- vim .fn [ ' dist#ft#SetFileTypeSH ' ]( ' bash' )
861+ eclass = function (path , bufnr )
862+ require ( ' vim.filetype.detect ' ). sh ( path , bufnr , ' bash' )
863863end ,
864864ent = function (path ,bufnr )
865865require (' vim.filetype.detect' ).ent (bufnr )
866866end ,
867- env = function ()
868- vim .fn [ ' dist#ft#SetFileTypeSH ' ]( vim .fn .getline (1 ))
867+ env = function (path , bufnr )
868+ require ( ' vim.filetype.detect ' ). sh ( path , bufnr , vim .fn .getline (1 ))
869869end ,
870870eu = function (path ,bufnr )
871871require (' vim.filetype.detect' ).euphoria (bufnr )
@@ -886,31 +886,31 @@ local extension = {
886886require (' vim.filetype.detect' ).frm (bufnr )
887887end ,
888888fs = function (path ,bufnr )
889- vim .fn [ ' dist#ft#FTfs ' ]( )
889+ require ( ' vim.filetype.detect ' ). fs ( bufnr )
890890end ,
891891h = function (path ,bufnr )
892892require (' vim.filetype.detect' ).header (bufnr )
893893end ,
894- htm = function ()
895- vim .fn [ ' dist#ft#FThtml ' ]( )
894+ htm = function (path , bufnr )
895+ require ( ' vim.filetype.detect ' ). html ( bufnr )
896896end ,
897- html = function ()
898- vim .fn [ ' dist#ft#FThtml ' ]( )
897+ html = function (path , bufnr )
898+ require ( ' vim.filetype.detect ' ). html ( bufnr )
899899end ,
900900i = function (path ,bufnr )
901901require (' vim.filetype.detect' ).progress_asm (bufnr )
902902end ,
903903idl = function (path ,bufnr )
904904require (' vim.filetype.detect' ).idl (bufnr )
905905end ,
906- inc = function ()
907- vim .fn [ ' dist#ft#FTinc ' ]( )
906+ inc = function (path , bufnr )
907+ require ( ' vim.filetype.detect ' ). inc ( bufnr )
908908end ,
909909inp = function (path ,bufnr )
910910require (' vim.filetype.detect' ).inp (bufnr )
911911end ,
912- ksh = function ()
913- vim .fn [ ' dist#ft#SetFileTypeSH ' ]( ' ksh' )
912+ ksh = function (path , bufnr )
913+ require ( ' vim.filetype.detect ' ). sh ( path , bufnr , ' ksh' )
914914end ,
915915lst = function (path ,bufnr )
916916require (' vim.filetype.detect' ).asm (bufnr )
@@ -941,17 +941,17 @@ local extension = {
941941return ' diff'
942942end
943943end ,
944- pl = function ()
945- vim .fn [ ' dist#ft#FTpl ' ]( )
944+ pl = function (path , bufnr )
945+ require ( ' vim.filetype.detect ' ). pl ( bufnr )
946946end ,
947- pp = function ()
948- vim .fn [ ' dist#ft#FTpp ' ]( )
947+ pp = function (path , bufnr )
948+ require ( ' vim.filetype.detect ' ). pp ( bufnr )
949949end ,
950- pro = function ()
951- vim .fn [ ' dist#ft#ProtoCheck ' ]( ' idlang' )
950+ pro = function (path , bufnr )
951+ require ( ' vim.filetype.detect ' ). proto ( bufnr , ' idlang' )
952952end ,
953- pt = function ()
954- vim .fn [ ' dist#ft#FThtml ' ]( )
953+ pt = function (path , bufnr )
954+ require ( ' vim.filetype.detect ' ). html ( ' idlang ' )
955955end ,
956956r = function (path ,bufnr )
957957require (' vim.filetype.detect' ).r (bufnr )
@@ -968,23 +968,23 @@ local extension = {
968968scd = function (path ,bufnr )
969969require (' vim.filetype.detect' ).scd (bufnr )
970970end ,
971- sh = function ()
972- vim .fn [ ' dist#ft#SetFileTypeSH ' ]( vim .fn .getline (1 ))
971+ sh = function (path , bufnr )
972+ require ( ' vim.filetype.detect ' ). sh ( path , bufnr , vim .fn .getline (1 ))
973973end ,
974- shtml = function ()
975- vim .fn [ ' dist#ft#FThtml ' ]( )
974+ shtml = function (path , bufnr )
975+ require ( ' vim.filetype.detect ' ). html ( bufnr )
976976end ,
977977sql = function (path ,bufnr )
978978require (' vim.filetype.detect' ).sql (bufnr )
979979end ,
980- stm = function ()
981- vim .fn [ ' dist#ft#FThtml ' ]( )
980+ stm = function (path , bufnr )
981+ require ( ' vim.filetype.detect ' ). html ( bufnr )
982982end ,
983- tcsh = function ()
984- vim .fn [ ' dist#ft#SetFileTypeShell ' ]( ' tcsh' )
983+ tcsh = function (path , bufnr )
984+ require ( ' vim.filetype.detect ' ). shell ( path , bufnr , ' tcsh' )
985985end ,
986- tex = function ()
987- vim .fn [ ' dist#ft#FTtex ' ]( )
986+ tex = function (path , bufnr )
987+ require ( ' vim.filetype.detect ' ). tex ( path , bufnr )
988988end ,
989989tf = function (path ,bufnr )
990990require (' vim.filetype.detect' ).tf (bufnr )
@@ -1300,63 +1300,63 @@ local filename = {
13001300 [' .zcompdump' ]= ' zsh' ,
13011301 [' .zshenv' ]= ' zsh' ,
13021302 [' .zfbfmarks' ]= ' zsh' ,
1303- [' .alias' ]= function ()
1304- vim .fn [ ' dist#ft#CSH ' ]( )
1303+ [' .alias' ]= function (path , bufnr )
1304+ require ( ' vim.filetype.detect ' ). csh ( path , bufnr )
13051305end ,
1306- [' .bashrc' ]= function ()
1307- vim .fn [ ' dist#ft#SetFileTypeSH ' ]( ' bash' )
1306+ [' .bashrc' ]= function (path , bufnr )
1307+ require ( ' vim.filetype.detect ' ). sh ( path , bufnr , ' bash' )
13081308end ,
1309- [' .cshrc' ]= function ()
1310- vim .fn [ ' dist#ft#CSH ' ]( )
1309+ [' .cshrc' ]= function (path , bufnr )
1310+ require ( ' vim.filetype.detect ' ). csh ( path , bufnr )
13111311end ,
1312- [' .env' ]= function ()
1313- vim .fn [ ' dist#ft#SetFileTypeSH ' ]( vim .fn .getline (1 ))
1312+ [' .env' ]= function (path , bufnr )
1313+ require ( ' vim.filetype.detect ' ). sh ( path , bufnr , vim .fn .getline (1 ))
13141314end ,
1315- [' .kshrc' ]= function ()
1316- vim .fn [ ' dist#ft#SetFileTypeSH ' ]( ' ksh' )
1315+ [' .kshrc' ]= function (path , bufnr )
1316+ require ( ' vim.filetype.detect ' ). sh ( path , bufnr , ' ksh' )
13171317end ,
1318- [' .login' ]= function ()
1319- vim .fn [ ' dist#ft#CSH ' ]( )
1318+ [' .login' ]= function (path , bufnr )
1319+ require ( ' vim.filetype.detect ' ). csh ( path , bufnr )
13201320end ,
1321- [' .profile' ]= function ()
1322- vim .fn [ ' dist#ft#SetFileTypeSH ' ]( vim .fn .getline (1 ))
1321+ [' .profile' ]= function (path , bufnr )
1322+ require ( ' vim.filetype.detect ' ). sh ( path , bufnr , vim .fn .getline (1 ))
13231323end ,
1324- [' .tcshrc' ]= function ()
1325- vim .fn [ ' dist#ft#SetFileTypeShell ' ]( ' tcsh' )
1324+ [' .tcshrc' ]= function (path , bufnr )
1325+ require ( ' vim.filetype.detect ' ). shell ( path , bufnr , ' tcsh' )
13261326end ,
1327- [' /etc/profile' ]= function ()
1328- vim .fn [ ' dist#ft#SetFileTypeSH ' ]( vim .fn .getline (1 ))
1327+ [' /etc/profile' ]= function (path , bufnr )
1328+ require ( ' vim.filetype.detect ' ). sh ( path , bufnr , vim .fn .getline (1 ))
13291329end ,
1330- APKBUILD = function ()
1331- vim .fn [ ' dist#ft#SetFileTypeSH ' ]( ' bash' )
1330+ APKBUILD = function (path , bufnr )
1331+ require ( ' vim.filetype.detect ' ). sh ( path , bufnr , ' bash' )
13321332end ,
1333- PKGBUILD = function ()
1334- vim .fn [ ' dist#ft#SetFileTypeSH ' ]( ' bash' )
1333+ PKGBUILD = function (path , bufnr )
1334+ require ( ' vim.filetype.detect ' ). sh ( path , bufnr , ' bash' )
13351335end ,
1336- [' bash.bashrc' ]= function ()
1337- vim .fn [ ' dist#ft#SetFileTypeSH ' ]( ' bash' )
1336+ [' bash.bashrc' ]= function (path , bufnr )
1337+ require ( ' vim.filetype.detect ' ). sh ( path , bufnr , ' bash' )
13381338end ,
1339- bashrc = function ()
1340- vim .fn [ ' dist#ft#SetFileTypeSH ' ]( ' bash' )
1339+ bashrc = function (path , bufnr )
1340+ require ( ' vim.filetype.detect ' ). sh ( path , bufnr , ' bash' )
13411341end ,
13421342crontab = starsetf (' crontab' ),
1343- [' csh.cshrc' ]= function ()
1344- vim .fn [ ' dist#ft#CSH ' ]( )
1343+ [' csh.cshrc' ]= function (path , bufnr )
1344+ require ( ' vim.filetype.detect ' ). csh ( path , bufnr )
13451345end ,
1346- [' csh.login' ]= function ()
1347- vim .fn [ ' dist#ft#CSH ' ]( )
1346+ [' csh.login' ]= function (path , bufnr )
1347+ require ( ' vim.filetype.detect ' ). csh ( path , bufnr )
13481348end ,
1349- [' csh.logout' ]= function ()
1350- vim .fn [ ' dist#ft#CSH ' ]( )
1349+ [' csh.logout' ]= function (path , bufnr )
1350+ require ( ' vim.filetype.detect ' ). csh ( path , bufnr )
13511351end ,
1352- [' indent.pro' ]= function ()
1353- vim .fn [ ' dist#ft#ProtoCheck ' ]( ' indent' )
1352+ [' indent.pro' ]= function (path , bufnr )
1353+ require ( ' vim.filetype.detect ' ). proto ( bufnr , ' indent' )
13541354end ,
1355- [' tcsh.login' ]= function ()
1356- vim .fn [ ' dist#ft#SetFileTypeShell ' ]( ' tcsh' )
1355+ [' tcsh.login' ]= function (path , bufnr )
1356+ require ( ' vim.filetype.detect ' ). shell ( path , bufnr , ' tcsh' )
13571357end ,
1358- [' tcsh.tcshrc' ]= function ()
1359- vim .fn [ ' dist#ft#SetFileTypeShell ' ]( ' tcsh' )
1358+ [' tcsh.tcshrc' ]= function (path , bufnr )
1359+ require ( ' vim.filetype.detect ' ). shell ( path , bufnr , ' tcsh' )
13601360end ,
13611361-- END FILENAME
13621362}
@@ -1528,32 +1528,32 @@ local pattern = {
15281528 [' .*/etc/xdg/menus/.*%.menu' ]= ' xml' ,
15291529 [' .*Xmodmap' ]= ' xmodmap' ,
15301530 [' .*/etc/zprofile' ]= ' zsh' ,
1531- [' %.bash[_-]aliases' ]= function ()
1532- vim .fn [ ' dist#ft#SetFileTypeSH ' ]( ' bash' )
1531+ [' %.bash[_-]aliases' ]= function (path , bufnr )
1532+ require ( ' vim.filetype.detect ' ). sh ( path , bufnr , ' bash' )
15331533end ,
1534- [' %.bash[_-]logout' ]= function ()
1535- vim .fn [ ' dist#ft#SetFileTypeSH ' ]( ' bash' )
1534+ [' %.bash[_-]logout' ]= function (path , bufnr )
1535+ require ( ' vim.filetype.detect ' ). sh ( path , bufnr , ' bash' )
15361536end ,
1537- [' %.bash[_-]profile' ]= function ()
1538- vim .fn [ ' dist#ft#SetFileTypeSH ' ]( ' bash' )
1537+ [' %.bash[_-]profile' ]= function (path , bufnr )
1538+ require ( ' vim.filetype.detect ' ). sh ( path , bufnr , ' bash' )
15391539end ,
1540- [' %.cshrc.*' ]= function ()
1541- vim .fn [ ' dist#ft#CSH ' ]( )
1540+ [' %.cshrc.*' ]= function (path , bufnr )
1541+ require ( ' vim.filetype.detect ' ). csh ( path , bufnr )
15421542end ,
15431543 [' %.gtkrc.*' ]= starsetf (' gtkrc' ),
1544- [' %.kshrc.*' ]= function ()
1545- vim .fn [ ' dist#ft#SetFileTypeSH ' ]( ' ksh' )
1544+ [' %.kshrc.*' ]= function (path , bufnr )
1545+ require ( ' vim.filetype.detect ' ). sh ( path , bufnr , ' ksh' )
15461546end ,
1547- [' %.login.*' ]= function ()
1548- vim .fn [ ' dist#ft#CSH ' ]( )
1547+ [' %.login.*' ]= function (path , bufnr )
1548+ require ( ' vim.filetype.detect ' ). csh ( path , bufnr )
15491549end ,
15501550 [' %.neomuttrc.*' ]= starsetf (' neomuttrc' ),
1551- [' %.profile.*' ]= function ()
1552- vim .fn [ ' dist#ft#SetFileTypeSH ' ]( vim .fn .getline (1 ))
1551+ [' %.profile.*' ]= function (path , bufnr )
1552+ require ( ' vim.filetype.detect ' ). sh ( path , bufnr , vim .fn .getline (1 ))
15531553end ,
15541554 [' %.reminders.*' ]= starsetf (' remind' ),
1555- [' %.tcshrc.*' ]= function ()
1556- vim .fn [ ' dist#ft#SetFileTypeShell ' ]( ' tcsh' )
1555+ [' %.tcshrc.*' ]= function (path , bufnr )
1556+ require ( ' vim.filetype.detect ' ). shell ( path , bufnr , ' tcsh' )
15571557end ,
15581558 [' %.zcompdump.*' ]= starsetf (' zsh' ),
15591559 [' %.zlog.*' ]= starsetf (' zsh' ),
@@ -1592,8 +1592,8 @@ local pattern = {
15921592 [' .*/etc/logcheck/.*%.d.*/.*' ]= starsetf (' logcheck' ),
15931593 [' .*/etc/modprobe%..*' ]= starsetf (' modconf' ),
15941594 [' .*/etc/pam%.d/.*' ]= starsetf (' pamconf' ),
1595- [' .*/etc/profile' ]= function ()
1596- vim .fn [ ' dist#ft#SetFileTypeSH ' ]( vim .fn .getline (1 ))
1595+ [' .*/etc/profile' ]= function (path , bufnr )
1596+ require ( ' vim.filetype.detect ' ). sh ( path , bufnr , vim .fn .getline (1 ))
15971597end ,
15981598 [' .*/etc/proftpd/.*%.conf.*' ]= starsetf (' apachestyle' ),
15991599 [' .*/etc/proftpd/conf%..*/.*' ]= starsetf (' apachestyle' ),
@@ -1621,8 +1621,8 @@ local pattern = {
16211621 [' access%.conf.*' ]= starsetf (' apache' ),
16221622 [' apache%.conf.*' ]= starsetf (' apache' ),
16231623 [' apache2%.conf.*' ]= starsetf (' apache' ),
1624- [' bash%-fc[-%.]' ]= function ()
1625- vim .fn [ ' dist#ft#SetFileTypeSH ' ]( ' bash' )
1624+ [' bash%-fc[-%.]' ]= function (path , bufnr )
1625+ require ( ' vim.filetype.detect ' ). sh ( path , bufnr , ' bash' )
16261626end ,
16271627 [' cabal%.project%..*' ]= starsetf (' cabalproject' ),
16281628 [' crontab%..*' ]= starsetf (' crontab' ),