vscode-cue icon indicating copy to clipboard operation
vscode-cue copied to clipboard

Define CUE TextMate grammar in CUE

Open myitcv opened this issue 4 years ago • 5 comments

Currently, the CUE TextMate Grammar is generated from a rather elegant Go specification.

However, as noted in https://github.com/cue-sh/vscode-cue/pull/12#issuecomment-889636913, the TextMate grammar exists in a JSON Schema form (there may be a more official location).

Hence we could quite easily move the specification of the CUE TextMate Grammar from Go to CUE, and have the code generation step be a cue export command (again, making sure this is part of CI).

@betawaffle - thoughts on this?

myitcv avatar Jul 30 '21 05:07 myitcv

That sounds like a great idea. The only reason I wrote it in Go originally was that I was very familiar (Go is my day job), and it was expedient. I think CUE probably wasn't mature enough for that at the time too.

betawaffle avatar Jul 30 '21 10:07 betawaffle

I think CUE probably wasn't mature enough for that at the time too.

That was almost certainly the case!

Thanks, I might suggest this to the CUE community as a project that someone could work on, unless you had a particular interest in it?

myitcv avatar Jul 30 '21 10:07 myitcv

unless you had a particular interest in it?

I would, but I'm really quite busy at the moment.

betawaffle avatar Jul 30 '21 10:07 betawaffle

I'll leave it marked as "help wanted" for now. Might tweet this out to see if there is anyone who might be interested in learning CUE with a particular goal to help that learning. Otherwise, we might do this as part of a live stream (we have some vague plans for doing more community-oriented stuff).

myitcv avatar Jul 30 '21 11:07 myitcv

Noting that https://github.com/Septh/tmlanguage exists, apparently as an enhanced fork.

myitcv avatar Aug 03 '21 08:08 myitcv