最后两个数组扩展没有得到正确的突出显示:
这是sh.nanorc
定义它的设置:
# More complicated variable names; handles braces and replacements and arrays.
color brightred "\$\{[#!]?([-@*#?$!]|[0-9]+|[[:alpha:]_][[:alnum:]_]*)(\[([[:space:]]*[[:alnum:]_]+[[:space:]]*|@)\])?(([#%/]|:?[-=?+])[^}]*\}|\[|\})"
我必须在正则表达式中修复什么才能赶上这个失误?