Skip to content

Commit

Permalink
Merge pull request #39 from markushaslinger/master
Browse files Browse the repository at this point in the history
Add asciidoc support
  • Loading branch information
danipen authored Nov 18, 2022
2 parents 36fd6a1 + a17c9a6 commit f95331c
Show file tree
Hide file tree
Showing 7 changed files with 1,854 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/TextMateSharp.Grammars.Tests/GrammarTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public void Get_Available_Languages_Should_Return_Content()
{
RegistryOptions options = new RegistryOptions(ThemeName.Light);

Assert.That(options.GetAvailableLanguages().Count, Is.EqualTo(60));
Assert.That(options.GetAvailableLanguages().Count, Is.EqualTo(61));
}

[Test]
Expand Down
1 change: 1 addition & 0 deletions src/TextMateSharp.Grammars/GrammarNames.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
internal class GrammarNames
{
internal static string[] SupportedGrammars = new string[] {
"Asciidoc",
"Bat",
"Clojure",
"CoffeeScript",
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
{
"registrations": [
{
"component": {
"type": "git",
"git": {
"name": "mattneub/AsciiDoc-TextMate-2.tmbundle",
"repositoryUrl": "https://github.com/mattneub/AsciiDoc-TextMate-2.tmbundle",
"commitHash": "df611ad3df9b71ebcc55351ee4e88e2dc0537957"
}
},
"licenseDetail": [
"Copyright (c) Matt Neuburg",
"",
"Probably MIT (http://choosealicense.com/licenses/mit/).",
"This seems closest to the Markdown bundle license which is what I would want to imitate.",
"Do what you want with it, don't pretend you wrote it if you didn't, and good luck to you.",
"https://github.com/mattneub/AsciiDoc-TextMate-2.tmbundle/issues/2#issuecomment-72376749"
],
"license": "MIT",
"version": "0.0.0"
}
],
"version": 1
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
{
"comments": {
"lineComment": "//",
"blockComment": [
"////",
"////"
]
},
"brackets": [
["{", "}"],
["[", "]"],
["(", ")"]
],
"autoClosingPairs": [
{
"open": "{",
"close": "}"
},
{
"open": "[",
"close": "]"
},
{
"open": "(",
"close": ")"
},
{
"open": "<",
"close": ">",
"notIn": [
"string"
]
}
],
"surroundingPairs": [
["(", ")"],
["[", "]"],
["`", "`"],
["_", "_"],
["*", "*"],
["{", "}"],
["'", "'"],
["\"", "\""]
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
{
"name": "asciidoc",
"displayName": "%displayName%",
"description": "%description%",
"version": "1.0.0",
"publisher": "Matt Neuburg",
"license": "MIT",
"engines": {
"vscode": "^1.20.0"
},
"contributes": {
"languages": [
{
"id": "asciidoc",
"aliases": [
"Asciidoc",
"asciidoc",
"Asciidoctor"
],
"extensions": [
".adoc"
],
"configuration": "./language-configuration.json"
}
],
"grammars": [
{
"language": "asciidoc",
"scopeName": "document.adoc",
"path": "./syntaxes/asciidoc.tmLanguage.json",
"embeddedLanguages": {
"meta.embedded.block.html": "html",
"source.js": "javascript",
"source.css": "css",
"meta.embedded.block.frontmatter": "yaml",
"meta.embedded.block.css": "css",
"meta.embedded.block.ini": "ini",
"meta.embedded.block.java": "java",
"meta.embedded.block.lua": "lua",
"meta.embedded.block.makefile": "makefile",
"meta.embedded.block.perl": "perl",
"meta.embedded.block.r": "r",
"meta.embedded.block.ruby": "ruby",
"meta.embedded.block.php": "php",
"meta.embedded.block.sql": "sql",
"meta.embedded.block.vs_net": "vs_net",
"meta.embedded.block.xml": "xml",
"meta.embedded.block.xsl": "xsl",
"meta.embedded.block.yaml": "yaml",
"meta.embedded.block.dosbatch": "dosbatch",
"meta.embedded.block.clojure": "clojure",
"meta.embedded.block.coffee": "coffee",
"meta.embedded.block.c": "c",
"meta.embedded.block.cpp": "cpp",
"meta.embedded.block.diff": "diff",
"meta.embedded.block.dockerfile": "dockerfile",
"meta.embedded.block.go": "go",
"meta.embedded.block.groovy": "groovy",
"meta.embedded.block.pug": "jade",
"meta.embedded.block.javascript": "javascript",
"meta.embedded.block.json": "json",
"meta.embedded.block.less": "less",
"meta.embedded.block.objc": "objc",
"meta.embedded.block.scss": "scss",
"meta.embedded.block.perl6": "perl6",
"meta.embedded.block.powershell": "powershell",
"meta.embedded.block.python": "python",
"meta.embedded.block.rust": "rust",
"meta.embedded.block.scala": "scala",
"meta.embedded.block.shellscript": "shellscript",
"meta.embedded.block.typescript": "typescript",
"meta.embedded.block.typescriptreact": "typescriptreact",
"meta.embedded.block.csharp": "csharp",
"meta.embedded.block.fsharp": "fsharp"
}
}
]
},
"repository": {
"type": "git",
"url": "https://github.com/microsoft/vscode.git"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"displayName": "Asciidoc Language Basics",
"description": "Provides syntax highlighting for Asciidoc."
}
Loading

0 comments on commit f95331c

Please sign in to comment.