adapt rc files to the new hook command

This commit is contained in:
Maxime Coste 2012-01-23 14:00:33 +00:00
parent a1ff9999f5
commit 950a734ce5
3 changed files with 10 additions and 7 deletions

View File

@ -1,5 +1,4 @@
hook WinInsertEnd .* exec xs\h+(?=\n)<ret>d hook global WinCreate .* addhl regex \h+(?=\n) default red
hook WinCreate .* addhl regex \h+(?=\n) default red
runtime rc/cpp.kak runtime rc/cpp.kak
runtime rc/kakrc.kak runtime rc/kakrc.kak

View File

@ -1,4 +1,4 @@
hook WinCreate .*\.(c|cc|cpp|cxx|C|h|hh|hpp|hxx|H) \ hook global WinCreate .*\.(c|cc|cpp|cxx|C|h|hh|hpp|hxx|H) \
addhl group hlcpp; \ addhl group hlcpp; \
addgrouphl hlcpp regex "\<(true|false|NULL|nullptr)\>|\<-?\d+[fdiu]?|'((\\.)?|[^'\\])'" red default; \ addgrouphl hlcpp regex "\<(true|false|NULL|nullptr)\>|\<-?\d+[fdiu]?|'((\\.)?|[^'\\])'" red default; \
addgrouphl hlcpp regex "\<(void|int|char|unsigned|float|bool|size_t)\>" yellow default; \ addgrouphl hlcpp regex "\<(void|int|char|unsigned|float|bool|size_t)\>" yellow default; \
@ -8,4 +8,6 @@ hook WinCreate .*\.(c|cc|cpp|cxx|C|h|hh|hpp|hxx|H) \
addgrouphl hlcpp regex "(\`|(?<=\n))\h*#\h*[^\n]*" magenta default; \ addgrouphl hlcpp regex "(\`|(?<=\n))\h*#\h*[^\n]*" magenta default; \
addgrouphl hlcpp regex "(//[^\n]*\n)|(/\*.*?(\*/|\'))" cyan default; \ addgrouphl hlcpp regex "(//[^\n]*\n)|(/\*.*?(\*/|\'))" cyan default; \
addfilter preserve_indent; \ addfilter preserve_indent; \
addfilter cleanup_whitespaces addfilter cleanup_whitespaces; \
hook window InsertEnd .* exec xs\h+(?=\n)<ret>d

View File

@ -1,7 +1,9 @@
hook WinCreate (.*/)?(kakrc|.*.kak) \ hook global WinCreate (.*/)?(kakrc|.*.kak) \
addhl group hlkakrc; \ addhl group hlkakrc; \
addgrouphl hlkakrc regex \<(hook|addhl|rmhl|addgrouphl|rmgrouphl|addfilter|rmfilter|exec|source|runtime)\> green default; \ addgrouphl hlkakrc regex \<(hook|addhl|rmhl|addgrouphl|rmgrouphl|addfilter|rmfilter|exec|source|runtime)\> green default; \
addgrouphl hlkakrc regex \<(default|black|red|green|yellow|blue|magenta|cyan|white)\> yellow default; \ addgrouphl hlkakrc regex \<(default|black|red|green|yellow|blue|magenta|cyan|white)\> yellow default; \
addgrouphl hlkakrc regex (?<=\<hook)\h+\w+\h+\H+ magenta default; \ addgrouphl hlkakrc regex (?<=\<hook)(\h+\w+){2}\h+\H+ magenta default; \
addgrouphl hlkakrc regex (?<=\<hook)\h+\w+ cyan default; \ addgrouphl hlkakrc regex (?<=\<hook)(\h+\w+){2} cyan default; \
addgrouphl hlkakrc regex (?<=\<hook)(\h+\w+) red default; \
addgrouphl hlkakrc regex (?<=\<hook)(\h+(global|window)) blue default; \
addgrouphl hlkakrc regex (?<=\<regex)\h+\H+ magenta default addgrouphl hlkakrc regex (?<=\<regex)\h+\H+ magenta default