Michael Jackson wrote:
Thanks. But how exactly are you "adding" those? By Hand or do you have some sort of script that parses CMake or .. ? It would be great if we could "sync up" the kate and some of the other editors to "standardize" on how the syntax coloring is broken down.

Obviously I am behind on reading this list :-) (see the message I just posted about unset not listed).

I have had, for some time, a script to generate keyword lists from cmake's built-in help.

The "meat" (arg extraction) looks like this:

extract_args() {
    sed -e '/'"$1"'(/ba' \
        -e 'd' \
        -e ':a' \
        -e '/)/{s/^.*(\(.*\)).*$/\1/p;d}' \
        -e 'N;s/\n/ /;ba' | \
    sed -e 's/[][]//g' -e 's/|\| \+/\n/g' | \
    sed -n '/^[[:upper:][:digit:]_]\+$/p' >> $t.args
}
while read COMMAND ; do
    "$CMAKE" --help-command $COMMAND | extract_args $COMMAND
done < $t.commands
sort $t.args | uniq > $t.argsu

I just don't want to reinvent the wheel unless I really need to. I would be happy to update my XML parser to add a kate syntax xml file generation...

Well, I'm already doing that... :-) What XML, though? Are you parsing 'cmake --help-html'? Or is there something that clearly delineates cmake keywords that I don't know about?

--
Matthew
Please do not quote my e-mail address unobfuscated in message bodies.
--
vIMprove your life! Now on version 7!

_______________________________________________
CMake mailing list
[email protected]
http://www.cmake.org/mailman/listinfo/cmake

Reply via email to