To: vim_dev@googlegroups.com Subject: Patch 8.2.4095 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ------------ Patch 8.2.4095 Problem: Sed script not recognized by the first line. Solution: Recognize a sed script starting with "#n". (Doug Kearns) Files: runtime/scripts.vim, src/testdir/test_filetype.vim *** ../vim-8.2.4094/runtime/scripts.vim 2022-01-05 20:56:34.633480269 +0000 --- runtime/scripts.vim 2022-01-15 12:24:10.933200775 +0000 *************** *** 406,411 **** --- 406,417 ---- elseif s:line1 =~# '^#.*by RouterOS.*$' set ft=routeros + " Sed scripts + " #ncomment is allowed but most likely a false positive so require a space + " before any trailing comment text + elseif s:line1 =~# '^#n\%($\|\s\)' + set ft=sed + " CVS diff else let s:lnum = 1 *** ../vim-8.2.4094/src/testdir/test_filetype.vim 2022-01-13 14:49:06.698083235 +0000 --- src/testdir/test_filetype.vim 2022-01-15 12:24:10.933200775 +0000 *************** *** 654,660 **** \ ['#!/path/nodejs'], \ ['#!/path/rhino']], \ 'bc': [['#!/path/bc']], ! \ 'sed': [['#!/path/sed']], \ 'ocaml': [['#!/path/ocaml']], \ 'awk': [['#!/path/awk'], \ ['#!/path/gawk']], --- 654,660 ---- \ ['#!/path/nodejs'], \ ['#!/path/rhino']], \ 'bc': [['#!/path/bc']], ! \ 'sed': [['#!/path/sed'], ['#n'], ['#n comment']], \ 'ocaml': [['#!/path/ocaml']], \ 'awk': [['#!/path/awk'], \ ['#!/path/gawk']], *** ../vim-8.2.4094/src/version.c 2022-01-15 10:52:08.268884075 +0000 --- src/version.c 2022-01-15 12:25:27.417056120 +0000 *************** *** 752,753 **** --- 752,755 ---- { /* Add new patch number below this line */ + /**/ + 4095, /**/ -- Q: How does a UNIX Guru do Sex ? A: unzip;strip;touch;finger;mount;fsck;more;yes;umount;sleep /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ /// \\\ \\\ sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ /// \\\ help me help AIDS victims -- http://ICCF-Holland.org ///