List of keywords, predefined names, symbols for codeless language module for BBEdit?

0 votes
asked Jan 13, 2020 in Question / help by rkrug (420 points)

Hi

I am writing a codless language module for BBEdit (http://www.barebones.com/support/develop/clm.html) to have syntax highlighting, folding, completion, ... for plantuml files in BBEdit.

For this, I need all the keywords, function names, predefined names, and grammar information (block delimiter, comments, ...). I could read through the examples, but is there an easier way of getting this list?

My initial attempts (less than alpha and still many leftovers from the R definition I started with) can be found at http://www.barebones.com/support/develop/clm.html - please feel free to contribute.

Cheers,

Rainer

commented Jan 13, 2020 by albert (3,520 points)

Did you have a look at the words as provided by:

java -Djava.awt.headless=true -jar plantuml.jar  -language

might also be useful when updating your keyword list.

commented Jan 13, 2020 by rkrug (420 points)
That's brilliant! I will implement these and come back with further questions.
commented Jan 20, 2020 by rkrug (420 points)
Just a follow up: what is the format of the output? Can I easily parse it to automate the creation of the keywords and predefined names?
commented Jan 20, 2020 by albert (3,520 points)
I think it is just a keyword line followed by a number of items followed by the items (and looks like an empty line as well at the end of each "keyword group".

I think it is a pure dump.
commented Jan 20, 2020 by rkrug (420 points)

Thanks to Freddy at stack exchange https://unix.stackexchange.com/a/563032/31511, the following code will split the output into several files named after the first line with a semicolon:

plantuml -language | awk -F';' '
  NF==0 { next }
  NF>1 { filename=$2; getline; next }
  { print > filename }
'
commented Jan 9, 2021 by vidge (100 points)

i ran the command "java -Djava.awt.headless=true -jar plantuml.jar -language" and noticed "then" keyword is missing in the output.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
Anti-spam verification:

[Antispam2 Feature: please please wait 1 or 2 minutes (this message will disappear) before pressing the button otherwise it will fail](--------)
To avoid this verification in future, please log in or register.
...