linguist icon indicating copy to clipboard operation
linguist copied to clipboard

Add Language: Imba

Open familyfriendlymikey opened this issue 2 years ago • 5 comments

Language name

Imba

URL of example repository

Imba.io repository

URL of syntax highlighting grammar

Imba's vscode extension

Most popular extensions

.imba

Detected language

Plain text

Popularity

Pull Request Information

  • Here's my fork, grammar compilation failed citing several PCRE errors, despite syntax highlighting working in VSCode.
  • Here's the source of the provided sample, MIT license.

Next Steps

In CONTRIBUTING.md it says

If problems are found, please report them to the grammar maintainer

I would very much appreciate some guidance on next steps. Thank you.

familyfriendlymikey avatar May 25 '22 02:05 familyfriendlymikey

There are 2,864 .imba files on GitHub.

I wonder how many files would show up if private repos could be counted too.

Also, as Imba requires much less configuration, and can express styling, markup and logic in a single language (and thus, a single file), the number of Imba files will always be "artifically low".

Crossing my fingers Imba can be included soon! 🤞 🤞

codeluggage avatar May 25 '22 16:05 codeluggage

And I was about to suggest Imba too. Cool!

MystPi avatar Jun 10 '22 13:06 MystPi

I would very much appreciate some guidance on next steps. Thank you.

Sure...

Here's my fork, grammar compilation failed citing several PCRE errors, despite syntax highlighting working in VSCode.

If you're seeing errors it's because you're using Oniguruma-specific expressions and/or are using very long expressions. This should be clear in the errors. These work on VSCode because it uses that regex engine which isn't particularly strict, however GitHub uses PCRE for performance reasons. In order to resolve those, you'll need to switch out the Oniguruma-specific expressions for PCRE-compatible expressions and ensure your expressions aren't too long and adhere to PCRE's limits.

lildude avatar Jun 10 '22 13:06 lildude

@familyfriendlymikey Maybe you could try pointing at

path = vendor/grammars/language-imba
url = https://github.com/somebee/language-imba

Instead of

path = vendor/grammars/vscode-imba
url = https://github.com/imba/vscode-imba.git

And see if it passes then? Would love to see imba included at some point!

somebee avatar Aug 12 '22 11:08 somebee

@lildude Thank you very much for explaining. I've fixed the expressions and submitted a PR: #6080

familyfriendlymikey avatar Sep 16 '22 21:09 familyfriendlymikey