Use POSIX -E of sed for extended regular expressions
This commit is contained in:
parent
2749093143
commit
2f05aebfff
|
@ -88,12 +88,12 @@ The syntaxic errors detected during parsing are shown when auto-diagnostics are
|
||||||
printf %s\\n "evaluate-commands -client ${kak_client} echo 'clang parsing done'" | kak -p ${kak_session}
|
printf %s\\n "evaluate-commands -client ${kak_client} echo 'clang parsing done'" | kak -p ${kak_session}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
flags=$(cat ${dir}/stderr | sed -rne "
|
flags=$(cat ${dir}/stderr | sed -Ene "
|
||||||
/^<stdin>:[0-9]+:([0-9]+:)? (fatal )?error/ { s/^<stdin>:([0-9]+):.*/'\1|{red}█'/; p }
|
/^<stdin>:[0-9]+:([0-9]+:)? (fatal )?error/ { s/^<stdin>:([0-9]+):.*/'\1|{red}█'/; p }
|
||||||
/^<stdin>:[0-9]+:([0-9]+:)? warning/ { s/^<stdin>:([0-9]+):.*/'\1|{yellow}█'/; p }
|
/^<stdin>:[0-9]+:([0-9]+:)? warning/ { s/^<stdin>:([0-9]+):.*/'\1|{yellow}█'/; p }
|
||||||
" | paste -s -d ' ' -)
|
" | paste -s -d ' ' -)
|
||||||
|
|
||||||
errors=$(cat ${dir}/stderr | sed -rne "
|
errors=$(cat ${dir}/stderr | sed -Ene "
|
||||||
/^<stdin>:[0-9]+:([0-9]+:)? ((fatal )?error|warning)/ {
|
/^<stdin>:[0-9]+:([0-9]+:)? ((fatal )?error|warning)/ {
|
||||||
s/'/''/g; s/^<stdin>:([0-9]+):([0-9]+:)? (.*)/'\1|\3'/; p
|
s/'/''/g; s/^<stdin>:([0-9]+):([0-9]+:)? (.*)/'\1|\3'/; p
|
||||||
}" | sort -n | paste -s -d ' ' -)
|
}" | sort -n | paste -s -d ' ' -)
|
||||||
|
|
|
@ -88,7 +88,7 @@ define-command ctags-funcinfo -docstring "Display ctags information about a sele
|
||||||
f=${kak_selection%?}
|
f=${kak_selection%?}
|
||||||
sig='\tsignature:(.*)'
|
sig='\tsignature:(.*)'
|
||||||
csn='\t(class|struct|namespace):(\S+)'
|
csn='\t(class|struct|namespace):(\S+)'
|
||||||
sigs=$(${kak_opt_readtagscmd} -e -Q '(eq? $kind "f")' "${f}" | sed -re "s/^.*${csn}.*${sig}$/\3 [\2::${f}]/ ;t ;s/^.*${sig}$/\1 [${f}]/")
|
sigs=$(${kak_opt_readtagscmd} -e -Q '(eq? $kind "f")' "${f}" | sed -Ee "s/^.*${csn}.*${sig}$/\3 [\2::${f}]/ ;t ;s/^.*${sig}$/\1 [${f}]/")
|
||||||
if [ -n "$sigs" ]; then
|
if [ -n "$sigs" ]; then
|
||||||
printf %s\\n "evaluate-commands -client ${kak_client} %{info -anchor $kak_cursor_line.$kak_cursor_column -style above '$sigs'}"
|
printf %s\\n "evaluate-commands -client ${kak_client} %{info -anchor $kak_cursor_line.$kak_cursor_column -style above '$sigs'}"
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in New Issue
Block a user