patch 8.2.4095: sed script not recognized by the first line
Problem: Sed script not recognized by the first line. Solution: Recognize a sed script starting with "#n". (Doug Kearns)
This commit is contained in:
@ -406,6 +406,12 @@ else
|
|||||||
elseif s:line1 =~# '^#.*by RouterOS.*$'
|
elseif s:line1 =~# '^#.*by RouterOS.*$'
|
||||||
set ft=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
|
" CVS diff
|
||||||
else
|
else
|
||||||
let s:lnum = 1
|
let s:lnum = 1
|
||||||
|
|||||||
@ -654,7 +654,7 @@ let s:script_checks = {
|
|||||||
\ ['#!/path/nodejs'],
|
\ ['#!/path/nodejs'],
|
||||||
\ ['#!/path/rhino']],
|
\ ['#!/path/rhino']],
|
||||||
\ 'bc': [['#!/path/bc']],
|
\ 'bc': [['#!/path/bc']],
|
||||||
\ 'sed': [['#!/path/sed']],
|
\ 'sed': [['#!/path/sed'], ['#n'], ['#n comment']],
|
||||||
\ 'ocaml': [['#!/path/ocaml']],
|
\ 'ocaml': [['#!/path/ocaml']],
|
||||||
\ 'awk': [['#!/path/awk'],
|
\ 'awk': [['#!/path/awk'],
|
||||||
\ ['#!/path/gawk']],
|
\ ['#!/path/gawk']],
|
||||||
|
|||||||
@ -750,6 +750,8 @@ static char *(features[]) =
|
|||||||
|
|
||||||
static int included_patches[] =
|
static int included_patches[] =
|
||||||
{ /* Add new patch number below this line */
|
{ /* Add new patch number below this line */
|
||||||
|
/**/
|
||||||
|
4095,
|
||||||
/**/
|
/**/
|
||||||
4094,
|
4094,
|
||||||
/**/
|
/**/
|
||||||
|
|||||||
Reference in New Issue
Block a user