Skip to content

Instantly share code, notes, and snippets.

@dunhamsteve
Created May 21, 2026 23:09
Show Gist options
  • Select an option

  • Save dunhamsteve/801e5eb326327838d9cebd9d0feeb96d to your computer and use it in GitHub Desktop.

Select an option

Save dunhamsteve/801e5eb326327838d9cebd9d0feeb96d to your computer and use it in GitHub Desktop.
BBEdit Language Module for Idris2
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>BBEditDocumentType</key>
<string>CodelessLanguageModule</string>
<key>BBLMLanguageCode</key>
<string>IDR2</string>
<key>BBLMLanguageDisplayName</key>
<string>Idris2</string>
<key>BBLMColorsSyntax</key>
<true/>
<key>BBLMCommentLineDefault</key>
<string>-- </string>
<key>BBLMCommentPrefixDefault</key>
<string>{-</string>
<key>BBLMCommentLineDefault</key>
<string>-}</string>
<key>BBLMIsCaseSensitive</key>
<true/>
<key>BBLMLanguageServerInfo</key>
<dict>
<key>ServerCommand</key>
<string>idris2-lsp</string>
<key>ServerInitParams</key>
<string></string>
<key>ServerLanguageID</key>
<string></string>
</dict>
<key>BBLMKeywordList</key>
<array>
<string>auto</string>
<string>autobind</string>
<string>case</string>
<string>constructor</string>
<string>covering</string>
<string>data</string>
<string>default</string>
<string>do</string>
<string>else</string>
<string>export</string>
<string>failing</string>
<string>forall</string>
<string>if</string>
<string>implementation</string>
<string>implicit</string>
<string>import</string>
<string>impossible</string>
<string>in</string>
<string>infix</string>
<string>infixl</string>
<string>infixr</string>
<string>interface</string>
<string>let</string>
<string>module</string>
<string>mutual</string>
<string>namespace</string>
<string>of</string>
<string>open</string>
<string>parameters</string>
<string>partial</string>
<string>prefix</string>
<string>private</string>
<string>proof</string>
<string>public</string>
<string>record</string>
<string>rewrite</string>
<string>then</string>
<string>total</string>
<string>typebind</string>
<string>using</string>
<string>where</string>
<string>with</string>
</array>
<key>BBLMScansFunctions</key>
<true/>
<key>BBLMSuffixMap</key>
<array>
<dict>
<key>BBLMLanguageSuffix</key>
<string>.idr</string>
</dict>
</array>
<key>BBLMSupportsTextCompletion</key>
<false/>
<key>Language Features</key>
<dict>
<key>Comment Pattern</key>
<string>--.*$</string>
<key>Function Pattern</key>
<!-- could use improvement, only does the first line -->
<string><![CDATA[^(?P<function>(?P<function_name>[\w\d_']+)\s*:.*)]]></string>
<key>Identifier and Keyword Character Class</key>
<string>A-Za-z0-9</string>
<key>Open Line Comments</key>
<string>--</string>
<key>String Pattern</key>
<string>("(\\"|[^"])*")</string>
</dict>
<key>com.barebones.DocumentType</key>
<string>CodelessLanguageModule</string>
</dict>
</plist>
@dunhamsteve

Copy link
Copy Markdown
Author

In settings (Cmd-,) go to languages, click "install language module", and select this file. It will use the LSP if installed and fall back to primitive highlighting otherwise. I'm not actively using BBEdit at the moment, but thought I would share this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment