From ab14a8f1afaf3d1e2f51dfce18bd8eea750c2390 Mon Sep 17 00:00:00 2001 From: Lars Vogel Date: Thu, 19 Dec 2024 13:00:13 +0100 Subject: [PATCH] Update of Asciidoc hyperlinking --- com.vogella.ide.editor.asciidoc/plugin.xml | 2 +- .../pom-for-review.xml | 27 - .../asciidoc/IncludeHyperlinkDetector.java | 40 +- .../syntaxes/asciidoc.json | 6707 ++++++++++++++++- .../syntaxes/asciidoc.tmLanguage | 2355 ------ 5 files changed, 6698 insertions(+), 2433 deletions(-) delete mode 100644 com.vogella.ide.editor.asciidoc/pom-for-review.xml delete mode 100644 com.vogella.ide.editor.asciidoc/syntaxes/asciidoc.tmLanguage diff --git a/com.vogella.ide.editor.asciidoc/plugin.xml b/com.vogella.ide.editor.asciidoc/plugin.xml index 2fd800f..44e3ab6 100644 --- a/com.vogella.ide.editor.asciidoc/plugin.xml +++ b/com.vogella.ide.editor.asciidoc/plugin.xml @@ -22,7 +22,7 @@ - - - 4.0.0 - - com.vogella.tycho - releng - 1.0.0-SNAPSHOT - - com.vogella.ide.editor.asciidoc - 1.0.0-SNAPSHOT - eclipse-plugin - [bundle] Asciidoc - - VOGELLA - - - src - - diff --git a/com.vogella.ide.editor.asciidoc/src/com/vogella/ide/editor/asciidoc/IncludeHyperlinkDetector.java b/com.vogella.ide.editor.asciidoc/src/com/vogella/ide/editor/asciidoc/IncludeHyperlinkDetector.java index ad4b0f0..3fb20ac 100644 --- a/com.vogella.ide.editor.asciidoc/src/com/vogella/ide/editor/asciidoc/IncludeHyperlinkDetector.java +++ b/com.vogella.ide.editor.asciidoc/src/com/vogella/ide/editor/asciidoc/IncludeHyperlinkDetector.java @@ -6,7 +6,6 @@ import org.eclipse.core.resources.IFile; import org.eclipse.core.resources.IResource; import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IPath; import org.eclipse.core.runtime.Path; import org.eclipse.e4.core.contexts.IEclipseContext; import org.eclipse.jface.text.BadLocationException; @@ -18,9 +17,6 @@ import org.eclipse.jface.text.hyperlink.IHyperlink; import org.eclipse.ui.IEditorInput; import org.eclipse.ui.IEditorPart; -import org.eclipse.ui.IWorkbench; -import org.eclipse.ui.IWorkbenchPage; -import org.eclipse.ui.IWorkbenchWindow; import org.eclipse.ui.PlatformUI; public class IncludeHyperlinkDetector extends AbstractHyperlinkDetector { @@ -47,23 +43,31 @@ public IHyperlink[] detectHyperlinks(ITextViewer textViewer, IRegion region, boo lineInformationOfOffset.getLength() - HYPERLINK_PROPERTY.length()); String fileName; -// // we support subfolder in the same level as we are - if (dependentResourceName.startsWith("../")||dependentResourceName.startsWith("./") ) { - - String folder = dependentResourceName.substring(0, dependentResourceName.lastIndexOf("/")); - dependentResourceName = dependentResourceName.substring(dependentResourceName.lastIndexOf("/")+1, dependentResourceName.length()); - IContainer subfolder = parent.getFolder(new Path(folder)); - parent = subfolder; + // Check if the dependent resource starts with "./" or "../" + if (dependentResourceName.startsWith("../") || dependentResourceName.startsWith("./")) { + + if (containsSubfolder(dependentResourceName)) { + // Handle cases with subdirectories + int lastSlashIndex = dependentResourceName.lastIndexOf("/"); + String folder = dependentResourceName.substring(0, lastSlashIndex); + dependentResourceName = dependentResourceName.substring(lastSlashIndex + 1); + IContainer subfolder = parent.getFolder(new Path(folder)); + parent = subfolder; + } else { + // Handle cases like "../exercise_settings.adoc" without a folder structure + dependentResourceName = dependentResourceName.substring(3); // Remove "../" + } } + if (!parent.exists()) { return null; } - - fileName= dependentResourceName; + + fileName = dependentResourceName; IResource[] members = parent.members(); - // Only take resources, which have the "adoc" file extension and skip the - // current resource itself + // Only take resources with the "adoc" file extension and skip the current + // resource itself IHyperlink[] result = Arrays.stream(members) .filter(res -> res instanceof IFile && res.getName().equals(fileName)) .map(res -> new ResourceHyperlink(targetRegion, res.getName(), (IFile) res)) @@ -80,6 +84,12 @@ public IHyperlink[] detectHyperlinks(ITextViewer textViewer, IRegion region, boo return null; } + public static boolean containsSubfolder(String relativePath) { + String normalizedPath = relativePath.replace("\\", "/"); // Normalize for cross-platform + int lastIndexOfParent = normalizedPath.lastIndexOf("../"); + return lastIndexOfParent != -1 && normalizedPath.indexOf("/", lastIndexOfParent + 3) != -1; + } + private IContainer getParentFolder() { IEclipseContext context = PlatformUI.getWorkbench().getService(IEclipseContext.class); Object object = context.get("activeEditor"); diff --git a/com.vogella.ide.editor.asciidoc/syntaxes/asciidoc.json b/com.vogella.ide.editor.asciidoc/syntaxes/asciidoc.json index 62d2bc3..80281e2 100644 --- a/com.vogella.ide.editor.asciidoc/syntaxes/asciidoc.json +++ b/com.vogella.ide.editor.asciidoc/syntaxes/asciidoc.json @@ -1,37 +1,6674 @@ { - "name": "AsciiDoc", - "scopeName": "source.asciidoc", - "fileTypes": [ - "adoc", - "asciidoc" - ], - "patterns": [ - { - "name": "markup.heading.asciidoc", - "match": "^(={1,5})\\s+.*$" - }, - { - "name": "markup.bold.asciidoc", - "begin": "\\*\\*", - "end": "\\*\\*" - }, - { - "name": "markup.italic.asciidoc", - "begin": "__", - "end": "__" - }, - { - "name": "markup.inline.raw.code.asciidoc", - "begin": "`", - "end": "`" - }, - { - "name": "markup.underline.link.asciidoc", - "match": "https?://[^\\s\\]]+" - }, - { - "name": "markup.image.asciidoc", - "match": "image::[^\\[]+\\[.*?\\]" - }, - ] + "name": "AsciiDoc", + "scopeName": "text.asciidoc", + "fileTypes": [ + "ad", + "asc", + "adoc", + "asciidoc", + "adoc.txt" + ], + "limitLineLength": false, + "maxTokensPerLine": 100, + "patterns": [ + { + "include": "#comment" + }, + { + "include": "#callout-list-item" + }, + { + "include": "#titles" + }, + { + "include": "#attribute-entry" + }, + { + "include": "#blocks" + }, + { + "include": "#block-title" + }, + { + "include": "#tables" + }, + { + "include": "#horizontal-rule" + }, + { + "include": "#list" + }, + { + "include": "#inlines" + }, + { + "include": "#block-attribute" + }, + { + "include": "#line-break" + } + ], + "repository": { + "blocks": { + "patterns": [ + { + "include": "#front-matter-block" + }, + { + "include": "#comment-paragraph" + }, + { + "include": "#admonition-paragraph" + }, + { + "include": "#quote-paragraph" + }, + { + "include": "#listing-paragraph" + }, + { + "include": "#source-paragraphs" + }, + { + "include": "#passthrough-paragraph" + }, + { + "include": "#example-paragraph" + }, + { + "include": "#sidebar-paragraph" + }, + { + "include": "#literal-paragraph" + }, + { + "include": "#open-block" + } + ] + }, + "source-paragraphs": { + "patterns": [ + { + "include": "#source-asciidoctor" + }, + { + "include": "#source-markdown" + } + ] + }, + "tables": { + "patterns": [ + { + "include": "#table-psv" + }, + { + "include": "#table-nested" + }, + { + "include": "#table-csv" + }, + { + "include": "#table-dsv" + } + ] + }, + "tables-includes": { + "patterns": [ + { + "include": "#comment" + }, + { + "include": "#callout-list-item" + }, + { + "include": "#attribute-entry" + }, + { + "include": "#block-title" + }, + { + "include": "#explicit-paragraph" + }, + { + "include": "#section" + }, + { + "include": "#blocks" + }, + { + "include": "#list" + }, + { + "include": "#inlines" + }, + { + "include": "#line-break" + } + ] + }, + "inlines": { + "patterns": [ + { + "include": "#typographic-quotes" + }, + { + "include": "#strong" + }, + { + "include": "#monospace" + }, + { + "include": "#emphasis" + }, + { + "include": "#superscript" + }, + { + "include": "#subscript" + }, + { + "include": "#mark" + }, + { + "include": "#general-block-macro" + }, + { + "include": "#anchor-macro" + }, + { + "include": "#footnote-macro" + }, + { + "include": "#image-macro" + }, + { + "include": "#kbd-macro" + }, + { + "include": "#link-macro" + }, + { + "include": "#stem-macro" + }, + { + "include": "#menu-macro" + }, + { + "include": "#passthrough-macro" + }, + { + "include": "#xref-macro" + }, + { + "include": "#attribute-reference" + }, + { + "include": "#characters" + }, + { + "include": "#bibtex-macro" + }, + { + "include": "#bibliography-anchor" + } + ] + }, + "attribute-entry": { + "patterns": [ + { + "name": "meta.definition.attribute-entry.asciidoc", + "begin": "^(:)(!?\\w.*?)(:)(\\p{Blank}+.+\\p{Blank}(?:\\+|\\\\))$", + "beginCaptures": { + "1": { + "name": "punctuation.separator.attribute-entry.asciidoc" + }, + "2": { + "name": "support.constant.attribute-name.asciidoc" + }, + "3": { + "name": "punctuation.separator.attribute-entry.asciidoc" + }, + "4": { + "name": "string.unquoted.attribute-value.asciidoc", + "patterns": [ + { + "include": "#inlines" + }, + { + "include": "#hard-break-backslash" + }, + { + "include": "#line-break" + }, + { + "include": "#line-break-backslash" + } + ] + } + }, + "contentName": "string.unquoted.attribute-value.asciidoc", + "patterns": [ + { + "include": "#inlines" + }, + { + "include": "#hard-break-backslash" + }, + { + "include": "#line-break" + }, + { + "include": "#line-break-backslash" + } + ], + "end": "^\\p{Blank}+.+$(?)(?=(?: ?)*$)", + "captures": { + "2": { + "name": "constant.other.symbol.asciidoc" + }, + "4": { + "name": "constant.numeric.asciidoc" + }, + "5": { + "name": "constant.other.symbol.asciidoc" + } + } + } + ] + }, + "block-title": { + "patterns": [ + { + "begin": "^\\.([^\\p{Blank}.].*)", + "captures": { + "1": { + "name": "markup.heading.blocktitle.asciidoc" + } + }, + "end": "$" + } + ] + }, + "callout-list-item": { + "patterns": [ + { + "name": "callout.asciidoc", + "match": "^(<)(\\d+)(>)\\p{Blank}+(.*)$", + "captures": { + "1": { + "name": "constant.other.symbol.asciidoc" + }, + "2": { + "name": "constant.numeric.asciidoc" + }, + "3": { + "name": "constant.other.symbol.asciidoc" + }, + "4": { + "patterns": [ + { + "include": "#inlines" + } + ] + } + } + } + ] + }, + "comment": { + "patterns": [ + { + "name": "comment.block.asciidoc", + "begin": "^(/{4,})$", + "patterns": [ + { + "include": "#inlines" + } + ], + "end": "^\\1$" + }, + { + "name": "comment.inline.asciidoc", + "match": "^/{2}([^/].*)?$" + } + ] + }, + "hard-break-backslash": { + "patterns": [ + { + "match": "(?<=\\S)\\p{Blank}+(\\+ \\\\)$", + "captures": { + "1": { + "name": "constant.other.symbol.hard-break.asciidoc" + } + } + } + ] + }, + "horizontal-rule": { + "patterns": [ + { + "name": "constant.other.symbol.horizontal-rule.asciidoc", + "match": "^(?:'|<){3,}$|^ {0,3}([-\\*'])( *)\\1\\2\\1$" + } + ] + }, + "include-directive": { + "patterns": [ + { + "match": "^(include)(::)([^\\[]+)(\\[)(.*?)(\\])$", + "captures": { + "1": { + "name": "entity.name.function.asciidoc" + }, + "2": { + "name": "punctuation.separator.asciidoc" + }, + "3": { + "name": "markup.link.asciidoc", + "patterns": [ + { + "include": "#attribute-reference" + } + ] + }, + "4": { + "name": "punctuation.separator.asciidoc" + }, + "5": { + "name": "string.unquoted.asciidoc", + "patterns": [ + { + "include": "#attribute-reference" + } + ] + }, + "6": { + "name": "punctuation.separator.asciidoc" + } + } + } + ] + }, + "keywords": { + "patterns": [ + { + "comment": "Admonition", + "name": "entity.name.function.asciidoc", + "match": "(NOTE|TIP|IMPORTANT|WARNING|CAUTION)" + }, + { + "comment": "Paragraph or verbatim", + "name": "entity.name.function.asciidoc", + "match": "(comment|example|literal|listing|normal|pass|quote|sidebar|source|verse|abstract|partintro)" + }, + { + "comment": "Diagram", + "name": "entity.name.function.asciidoc", + "match": "(actdiag|blockdiag|ditaa|graphviz|meme|mermaid|nwdiag|packetdiag|pikchr|plantuml|rackdiag|seqdiag|shaape|wavedrom)" + }, + { + "comment": "Others", + "name": "entity.name.function.asciidoc", + "match": "(sect[1-4]|preface|colophon|dedication|glossary|bibliography|synopsis|appendix|index|normal|partintro|music|latex|stem)" + } + ] + }, + "line-break-backslash": { + "patterns": [ + { + "match": "(?<=\\S)\\p{Blank}+(\\\\)$", + "captures": { + "1": { + "name": "variable.line-break.asciidoc" + } + } + } + ] + }, + "line-break": { + "patterns": [ + { + "match": "(?<=\\S)\\p{Blank}+(\\+)$", + "captures": { + "1": { + "name": "variable.line-break.asciidoc" + } + } + } + ] + }, + "list": { + "patterns": [ + { + "match": "^\\s*(-)\\p{Blank}(\\[[\\p{Blank}\\*x]\\])(?=\\p{Blank})", + "name": "markup.todo.asciidoc", + "captures": { + "1": { + "name": "markup.list.bullet.asciidoc" + }, + "2": { + "name": "markup.todo.box.asciidoc" + } + } + }, + { + "name": "markup.list.asciidoc", + "match": "^\\p{Blank}*(-|\\*{1,5}|\\u2022{1,5})(?=\\p{Blank})", + "captures": { + "1": { + "name": "markup.list.bullet.asciidoc" + } + } + }, + { + "name": "markup.list.asciidoc", + "match": "^\\p{Blank}*(\\.{1,5}|\\d+\\.|[a-zA-Z]\\.|[IVXivx]+\\))(?=\\p{Blank})", + "captures": { + "1": { + "name": "markup.list.bullet.asciidoc" + } + } + }, + { + "name": "markup.heading.list.asciidoc", + "match": "^\\p{Blank}*(.*?\\S)(:{2,4}|;;)($|\\p{Blank}+)", + "captures": { + "1": { + "patterns": [ + { + "include": "#link-macro" + }, + { + "include": "#attribute-reference" + } + ] + }, + "2": { + "name": "markup.list.bullet.asciidoc" + } + } + } + ] + }, + "titles": { + "patterns": [ + { + "name": "markup.heading.heading-5.asciidoc", + "begin": "^((?:=|#){6})([\\p{Blank}]+)(?=\\S+)", + "end": "$", + "beginCaptures": { + "1": { + "name": "markup.heading.marker.asciidoc" + }, + "2": { + "name": "markup.heading.space.asciidoc" + } + }, + "patterns": [ + { + "include": "$self" + } + ] + }, + { + "name": "markup.heading.heading-4.asciidoc", + "begin": "^((?:=|#){5})([\\p{Blank}]+)(?=\\S+)", + "end": "$", + "beginCaptures": { + "1": { + "name": "markup.heading.marker.asciidoc" + }, + "2": { + "name": "markup.heading.space.asciidoc" + } + }, + "patterns": [ + { + "include": "$self" + } + ] + }, + { + "name": "markup.heading.heading-3.asciidoc", + "begin": "^((?:=|#){4})([\\p{Blank}]+)(?=\\S+)", + "end": "$", + "beginCaptures": { + "1": { + "name": "markup.heading.marker.asciidoc" + }, + "2": { + "name": "markup.heading.space.asciidoc" + } + }, + "patterns": [ + { + "include": "$self" + } + ] + }, + { + "name": "markup.heading.heading-2.asciidoc", + "begin": "^((?:=|#){3})([\\p{Blank}]+)(?=\\S+)", + "end": "$", + "beginCaptures": { + "1": { + "name": "markup.heading.marker.asciidoc" + }, + "2": { + "name": "markup.heading.space.asciidoc" + } + }, + "patterns": [ + { + "include": "$self" + } + ] + }, + { + "name": "markup.heading.heading-1.asciidoc", + "begin": "^((?:=|#){2})([\\p{Blank}]+)(?=\\S+)", + "end": "$", + "beginCaptures": { + "1": { + "name": "markup.heading.marker.asciidoc" + }, + "2": { + "name": "markup.heading.space.asciidoc" + } + }, + "patterns": [ + { + "include": "$self" + } + ] + }, + { + "name": "markup.heading.heading-0.asciidoc", + "begin": "^((?:=|#){1})([\\p{Blank}]+)(?=\\S+)", + "end": "$", + "beginCaptures": { + "1": { + "name": "markup.heading.marker.asciidoc" + }, + "2": { + "name": "markup.heading.space.asciidoc" + } + }, + "patterns": [ + { + "include": "$self" + } + ] + } + ] + }, + "anchor-macro": { + "patterns": [ + { + "name": "markup.other.anchor.asciidoc", + "match": "(?\\(\\)\\[\\];])((?\\(\\)\\[\\];])((?\\+{2,3}|\\${2})(.*?)(\\k)", + "captures": { + "1": { + "name": "markup.meta.attribute-list.asciidoc" + }, + "3": { + "name": "support.constant.asciidoc" + }, + "4": { + "name": "string.unquoted.asciidoc", + "patterns": [ + { + "include": "text.html.basic" + } + ] + }, + "5": { + "name": "support.constant.asciidoc" + } + } + }, + { + "name": "markup.macro.inline.passthrough.asciidoc", + "begin": "(?>))", + "captures": { + "1": { + "name": "constant.asciidoc" + }, + "2": { + "name": "markup.meta.attribute-list.asciidoc" + }, + "3": { + "name": "string.unquoted.asciidoc" + }, + "4": { + "name": "constant.asciidoc" + } + } + }, + { + "name": "markup.reference.xref.asciidoc", + "begin": "(?(?:^\\[(NOTE|TIP|IMPORTANT|WARNING|CAUTION)((?:,|#|\\.|%)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(NOTE|TIP|IMPORTANT|WARNING|CAUTION)((?:,|#|\\.|%)([^,\\]]+))*\\]$", + "captures": { + "0": { + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "example block", + "begin": "^(={4,})\\s*$", + "patterns": [ + { + "include": "#inlines" + }, + { + "include": "#list" + } + ], + "end": "(?<=\\1)" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "patterns": [ + { + "include": "#inlines" + }, + { + "include": "#list" + } + ], + "end": "(?<=\\1)" + } + ], + "end": "((?<=--|====)$|^\\p{Blank}*$)" + }, + { + "name": "markup.admonition.asciidoc", + "begin": "^(NOTE|TIP|IMPORTANT|WARNING|CAUTION)\\:\\p{Blank}+", + "captures": { + "1": { + "name": "entity.name.function.asciidoc" + } + }, + "patterns": [ + { + "include": "#inlines" + } + ], + "end": "^\\p{Blank}*$" + } + ] + }, + "comment-paragraph": { + "patterns": [ + { + "name": "comment.block.asciidoc", + "begin": "(?=(?>(?:^\\[(comment)((?:,|#|\\.|%)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(comment)((?:,|#|\\.|%)([^,\\]]+))*\\]$", + "captures": { + "0": { + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#block-title" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "patterns": [ + { + "include": "#inlines" + }, + { + "include": "#list" + } + ], + "end": "^(\\1)$" + }, + { + "include": "#inlines" + } + ], + "end": "((?<=--)$|^\\p{Blank}*$)" + } + ] + }, + "example-paragraph": { + "patterns": [ + { + "name": "markup.block.example.asciidoc", + "begin": "(?=(?>(?:^\\[(example)((?:,|#|\\.|%)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(example)((?:,|#|\\.|%)([^,\\]]+))*\\]$", + "captures": { + "0": { + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#block-title" + }, + { + "comment": "example block", + "begin": "^(={4,})$", + "patterns": [ + { + "include": "$self" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})$", + "patterns": [ + { + "include": "$self" + } + ], + "end": "^(\\1)$" + }, + { + "include": "#inlines" + } + ], + "end": "((?<=--|====)$|^\\p{Blank}*$)" + }, + { + "name": "markup.block.example.asciidoc", + "begin": "^(={4,})$", + "patterns": [ + { + "include": "$self" + } + ], + "end": "^(\\1)$" + } + ] + }, + "front-matter-block": { + "patterns": [ + { + "name": "markup.block.front-matter.asciidoc", + "begin": "\\A(-{3}$)", + "patterns": [ + { + "include": "source.yaml" + } + ], + "end": "^(\\1)$" + } + ] + }, + "listing-paragraph": { + "patterns": [ + { + "name": "markup.block.listing.asciidoc", + "begin": "(?=(?>(?:^\\[(listing)((?:,|#|\\.|%)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(listing)((?:,|#|\\.|%)([^,\\]]+))*\\]$", + "captures": { + "0": { + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "end": "^(\\1)$" + }, + { + "include": "#inlines" + } + ], + "end": "((?<=--)$|^\\p{Blank}*$)" + } + ] + }, + "literal-paragraph": { + "patterns": [ + { + "name": "markup.block.literal.asciidoc", + "begin": "(?=(?>(?:^\\[(literal)((?:,|#|\\.|%)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(literal)((?:,|#|\\.|%)([^,\\]]+))*\\]$", + "captures": { + "0": { + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#block-title" + }, + { + "comment": "literal block", + "begin": "^(\\.{4,})$", + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "end": "^(\\1)$" + }, + { + "include": "#inlines" + } + ], + "end": "((?<=--|\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.block.literal.asciidoc", + "begin": "^(\\.{4,})$", + "end": "^(\\1)$" + } + ] + }, + "open-block": { + "patterns": [ + { + "name": "markup.block.open.asciidoc", + "begin": "^(-{2})$", + "beginCaptures": { + "1": { + "name": "constant.other.symbol.asciidoc" + } + }, + "patterns": [ + { + "include": "$self" + } + ], + "end": "^(\\1)$", + "endCaptures": { + "1": { + "name": "constant.other.symbol.asciidoc" + } + } + } + ] + }, + "passthrough-paragraph": { + "patterns": [ + { + "name": "markup.block.passthrough.asciidoc", + "begin": "(?=(?>(?:^\\[(pass)((?:,|#|\\.|%)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(pass)((?:,|#|\\.|%)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#block-title" + }, + { + "comment": "passthrough block", + "begin": "^(\\+{4,})\\s*$", + "patterns": [ + { + "include": "text.html.basic" + } + ], + "end": "(?<=\\1)" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "patterns": [ + { + "include": "text.html.basic" + } + ], + "end": "(?<=\\1)" + } + ], + "end": "((?<=--|\\+\\+)$|^\\p{Blank}*$)" + }, + { + "name": "markup.block.passthrough.asciidoc", + "begin": "(^\\+{4,}$)", + "patterns": [ + { + "include": "text.html.basic" + } + ], + "end": "\\1" + } + ] + }, + "quote-paragraph": { + "patterns": [ + { + "name": "markup.italic.quotes.asciidoc", + "begin": "(?=(?>(?:^\\[(quote|verse)((?:,|#|\\.|%)([^,\\]]+))*\\]$)))", + "patterns": [ + { + "match": "^\\[(quote|verse)((?:,|#|\\.|%)([^,\\]]+))*\\]$", + "captures": { + "0": { + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#block-title" + }, + { + "include": "#inlines" + }, + { + "comment": "quotes block", + "begin": "^([_]{4,})\\s*$", + "patterns": [ + { + "include": "#inlines" + }, + { + "include": "#list" + } + ], + "end": "(?<=\\1)" + }, + { + "comment": "air quotes", + "begin": "^(\"{2})\\s*$", + "patterns": [ + { + "include": "#inlines" + }, + { + "include": "#list" + } + ], + "end": "(?<=\\1)" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "patterns": [ + { + "include": "#inlines" + }, + { + "include": "#list" + } + ], + "end": "(?<=\\1)$" + } + ], + "end": "((?<=____|\"\"|--)$|^\\p{Blank}*$)" + }, + { + "name": "markup.italic.quotes.asciidoc", + "begin": "^(\"\")$", + "patterns": [ + { + "include": "#inlines" + }, + { + "include": "#list" + } + ], + "end": "^\\1$" + }, + { + "name": "markup.italic.quotes.asciidoc", + "begin": "^\\p{Blank}*(>) ", + "patterns": [ + { + "include": "#inlines" + }, + { + "include": "#list" + } + ], + "end": "^\\p{Blank}*?$" + } + ] + }, + "sidebar-paragraph": { + "patterns": [ + { + "name": "markup.block.sidebar.asciidoc", + "begin": "(?=(?>(?:^\\[(sidebar)((?:,|#|\\.|%)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(sidebar)((?:,|#|\\.|%)([^,\\]]+))*\\]$", + "captures": { + "0": { + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#block-title" + }, + { + "comment": "sidebar block", + "begin": "^(\\*{4,})$", + "patterns": [ + { + "include": "$self" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})$", + "patterns": [ + { + "include": "$self" + } + ], + "end": "^(\\1)$" + }, + { + "include": "#inlines" + } + ], + "end": "((?<=--|\\*\\*\\*\\*)$|^\\p{Blank}*$)" + }, + { + "name": "markup.block.sidebar.asciidoc", + "begin": "^(\\*{4,})$", + "patterns": [ + { + "include": "$self" + } + ], + "end": "^(\\1)$" + } + ] + }, + "table-csv": { + "patterns": [ + { + "name": "markup.table.csv.asciidoc", + "begin": "^(,===)$", + "beginCaptures": { + "0": { + "name": "markup.table.delimiter.asciidoc" + } + }, + "contentName": "string.unquoted.asciidoc", + "patterns": [ + { + "include": "text.csv" + }, + { + "comment": "cell separator", + "match": ",", + "captures": { + "0": { + "name": "markup.table.cell.delimiter.asciidoc" + } + } + }, + { + "include": "#general-block-macro" + } + ], + "end": "^(\\1)$", + "endCaptures": { + "0": { + "name": "markup.table.delimiter.asciidoc" + } + } + } + ] + }, + "table-dsv": { + "patterns": [ + { + "name": "markup.table.dsv.asciidoc", + "begin": "^(:===)$", + "beginCaptures": { + "0": { + "name": "markup.table.delimiter.asciidoc" + } + }, + "contentName": "string.unquoted.asciidoc", + "patterns": [ + { + "comment": "cell separator", + "match": ":", + "captures": { + "0": { + "name": "markup.table.cell.delimiter.asciidoc" + } + } + }, + { + "include": "#general-block-macro" + } + ], + "end": "^(\\1)$", + "endCaptures": { + "0": { + "name": "markup.table.delimiter.asciidoc" + } + } + } + ] + }, + "table-nested": { + "patterns": [ + { + "name": "markup.table.nested.asciidoc", + "begin": "^(!===)$", + "beginCaptures": { + "0": { + "name": "markup.table.delimiter.asciidoc" + } + }, + "contentName": "markup.table.content.asciidoc", + "patterns": [ + { + "comment": "cell separator and attributes", + "match": "(^|[^\\p{Blank}\\\\]*)(?(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(c))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(c))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.c", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.c" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.c", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.c" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.c", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.c" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.clojure.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(clojure))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(clojure))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.clojure", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.clojure" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.clojure", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.clojure" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.clojure", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.clojure" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.coffee.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(coffee-?(script)?))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(coffee-?(script)?))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.coffee", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.coffee" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.coffee", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.coffee" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.coffee", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.coffee" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.cpp.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(c(pp|\\+\\+)))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(c(pp|\\+\\+)))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.cpp", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.cpp" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.cpp", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.cpp" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.cpp", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.cpp" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.css.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(css))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(css))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.css", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.css" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.css", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.css" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.css", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.css" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.cs.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(cs(harp)?))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(cs(harp)?))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.cs", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.cs" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.cs", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.cs" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.cs", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.cs" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.diff.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(diff|patch|rej))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(diff|patch|rej))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.diff", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.diff" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.diff", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.diff" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.diff", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.diff" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.dockerfile.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(docker(file)?))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(docker(file)?))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.dockerfile", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.dockerfile" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.dockerfile", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.dockerfile" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.dockerfile", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.dockerfile" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.elixir.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(elixir))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(elixir))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.elixir", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.elixir" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.elixir", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.elixir" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.elixir", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.elixir" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.elm.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(elm))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(elm))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.elm", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.elm" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.elm", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.elm" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.elm", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.elm" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.erlang.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(erlang))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(erlang))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.erlang", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.erlang" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.erlang", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.erlang" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.erlang", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.erlang" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.go.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(go(lang)?))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(go(lang)?))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.go", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.go" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.go", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.go" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.go", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.go" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.groovy.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(groovy))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(groovy))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.groovy", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.groovy" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.groovy", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.groovy" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.groovy", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.groovy" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.haskell.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(haskell))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(haskell))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.haskell", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.haskell" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.haskell", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.haskell" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.haskell", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.haskell" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.html.basic.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(html))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(html))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "text.embedded.html.basic", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "text.html.basic" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "text.embedded.html.basic", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "text.html.basic" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "text.embedded.html.basic", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "text.html.basic" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.java.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(java))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(java))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.java", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.java" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.java", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.java" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.java", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.java" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.js.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(javascript|js))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(javascript|js))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.js", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.js" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.js", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.js" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.js", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.js" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.json.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(json))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(json))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.json", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.json" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.json", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.json" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.json", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.json" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.js.jsx.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(jsx))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(jsx))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.js.jsx", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.js.jsx" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.js.jsx", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.js.jsx" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.js.jsx", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.js.jsx" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.julia.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(julia))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(julia))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.julia", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.julia" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.julia", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.julia" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.julia", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.julia" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.kotlin.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(kotlin|kts?))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(kotlin|kts?))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.kotlin", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.kotlin" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.kotlin", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.kotlin" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.kotlin", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.kotlin" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.css.less.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(less))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(less))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.css.less", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.css.less" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.css.less", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.css.less" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.css.less", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.css.less" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.makefile.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(make(file)?))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(make(file)?))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.makefile", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.makefile" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.makefile", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.makefile" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.makefile", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.makefile" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.gfm.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(markdown|mdown|md))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(markdown|mdown|md))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.gfm", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.gfm" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.gfm", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.gfm" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.gfm", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.gfm" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.html.mustache.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(mustache))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(mustache))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "text.embedded.html.mustache", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "text.html.mustache" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "text.embedded.html.mustache", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "text.html.mustache" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "text.embedded.html.mustache", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "text.html.mustache" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.objc.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(objc|objective-c))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(objc|objective-c))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.objc", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.objc" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.objc", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.objc" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.objc", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.objc" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.ocaml.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(ocaml))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(ocaml))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.ocaml", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.ocaml" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.ocaml", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.ocaml" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.ocaml", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.ocaml" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.perl.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(perl))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(perl))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.perl", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.perl" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.perl", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.perl" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.perl", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.perl" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.perl6.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(perl6))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(perl6))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.perl6", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.perl6" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.perl6", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.perl6" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.perl6", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.perl6" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.html.php.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(php))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(php))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "text.embedded.html.php", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "text.html.php" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "text.embedded.html.php", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "text.html.php" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "text.embedded.html.php", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "text.html.php" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.asciidoc.properties.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(properties))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(properties))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.asciidoc.properties", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.asciidoc.properties" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.asciidoc.properties", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.asciidoc.properties" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.asciidoc.properties", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.asciidoc.properties" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.python.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(py(thon)?))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(py(thon)?))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.python", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.python" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.python", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.python" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.python", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.python" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.r.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(r))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(r))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.r", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.r" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.r", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.r" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.r", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.r" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.ruby.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(ruby|rb))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(ruby|rb))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.ruby", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.ruby" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.ruby", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.ruby" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.ruby", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.ruby" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.rust.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(rust|rs))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(rust|rs))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.rust", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.rust" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.rust", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.rust" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.rust", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.rust" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.sass.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(sass))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(sass))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.sass", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.sass" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.sass", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.sass" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.sass", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.sass" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.scala.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(scala))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(scala))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.scala", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.scala" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.scala", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.scala" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.scala", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.scala" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.css.scss.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(scss))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(scss))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.css.scss", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.css.scss" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.css.scss", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.css.scss" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.css.scss", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.css.scss" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.shell.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(sh|bash|shell))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(sh|bash|shell))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.shell", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.shell" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.shell", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.shell" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.shell", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.shell" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.sql.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(sql))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(sql))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.sql", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.sql" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.sql", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.sql" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.sql", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.sql" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.swift.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(swift))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(swift))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.swift", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.swift" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.swift", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.swift" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.swift", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.swift" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.toml.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(toml))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(toml))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.toml", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.toml" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.toml", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.toml" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.toml", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.toml" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.ts.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(typescript|ts))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(typescript|ts))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.ts", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.ts" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.ts", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.ts" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.ts", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.ts" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.xml.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(xml))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(xml))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "text.embedded.xml", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "text.xml" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "text.embedded.xml", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "text.xml" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "text.embedded.xml", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "text.xml" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.code.yaml.asciidoc", + "begin": "(?=(?>(?:^\\[(source)(?:,|#)\\p{Blank}*(?i:(ya?ml))((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)(?:,|#)\\p{Blank}*(?i:(ya?ml))((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "begin": "^(-{4,})\\s*$", + "contentName": "source.embedded.yaml", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.yaml" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "begin": "^(-{2})\\s*$", + "contentName": "source.embedded.yaml", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.yaml" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "begin": "^(\\.{4})\\s*$", + "contentName": "source.embedded.yaml", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + }, + { + "include": "source.yaml" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "begin": "(?=(?>(?:^\\[(source)((?:,|#)[^\\]]+)*\\]$)))", + "patterns": [ + { + "match": "^\\[(source)((?:,|#)([^,\\]]+))*\\]$", + "captures": { + "0": { + "name": "markup.heading.asciidoc", + "patterns": [ + { + "include": "#block-attribute-inner" + } + ] + } + } + }, + { + "include": "#inlines" + }, + { + "include": "#block-title" + }, + { + "comment": "listing block", + "name": "markup.raw.asciidoc", + "begin": "^(-{4,})\\s*$", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "open block", + "name": "markup.raw.asciidoc", + "begin": "^(-{2})\\s*$", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + } + ], + "end": "^(\\1)$" + }, + { + "comment": "literal block", + "name": "markup.raw.asciidoc", + "begin": "^(\\.{4})\\s*$", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + } + ], + "end": "^(\\1)$" + } + ], + "end": "((?<=--|\\.\\.\\.\\.)$|^\\p{Blank}*$)" + }, + { + "name": "markup.raw.asciidoc", + "begin": "^(-{4,})\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "#include-directive" + } + ], + "end": "^(\\1)$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + } + ] + }, + "source-markdown": { + "patterns": [ + { + "name": "markup.code.c.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(c))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.c", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.c" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.clojure.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(clojure))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.clojure", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.clojure" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.coffee.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(coffee-?(script)?))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.coffee", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.coffee" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.cpp.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(c(pp|\\+\\+)))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.cpp", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.cpp" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.css.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(css))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.css", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.css" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.cs.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(cs(harp)?))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.cs", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.cs" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.diff.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(diff|patch|rej))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.diff", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.diff" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.dockerfile.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(docker(file)?))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.dockerfile", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.dockerfile" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.elixir.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(elixir))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.elixir", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.elixir" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.elm.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(elm))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.elm", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.elm" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.erlang.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(erlang))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.erlang", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.erlang" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.go.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(go(lang)?))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.go", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.go" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.groovy.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(groovy))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.groovy", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.groovy" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.haskell.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(haskell))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.haskell", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.haskell" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.html.basic.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(html))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "text.embedded.html.basic", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "text.html.basic" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.java.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(java))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.java", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.java" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.js.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(javascript|js))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.js", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.js" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.json.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(json))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.json", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.json" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.js.jsx.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(jsx))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.js.jsx", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.js.jsx" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.julia.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(julia))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.julia", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.julia" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.kotlin.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(kotlin|kts?))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.kotlin", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.kotlin" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.css.less.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(less))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.css.less", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.css.less" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.makefile.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(make(file)?))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.makefile", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.makefile" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.gfm.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(markdown|mdown|md))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.gfm", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.gfm" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.html.mustache.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(mustache))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "text.embedded.html.mustache", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "text.html.mustache" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.objc.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(objc|objective-c))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.objc", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.objc" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.ocaml.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(ocaml))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.ocaml", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.ocaml" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.perl.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(perl))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.perl", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.perl" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.perl6.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(perl6))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.perl6", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.perl6" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.html.php.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(php))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "text.embedded.html.php", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "text.html.php" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.asciidoc.properties.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(properties))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.asciidoc.properties", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.asciidoc.properties" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.python.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(py(thon)?))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.python", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.python" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.r.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(r))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.r", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.r" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.ruby.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(ruby|rb))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.ruby", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.ruby" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.rust.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(rust|rs))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.rust", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.rust" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.sass.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(sass))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.sass", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.sass" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.scala.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(scala))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.scala", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.scala" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.css.scss.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(scss))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.css.scss", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.css.scss" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.shell.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(sh|bash|shell))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.shell", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.shell" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.sql.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(sql))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.sql", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.sql" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.swift.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(swift))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.swift", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.swift" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.toml.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(toml))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.toml", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.toml" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.ts.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(typescript|ts))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.ts", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.ts" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.xml.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(xml))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "text.embedded.xml", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "text.xml" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.code.yaml.asciidoc", + "begin": "^\\s*(`{3,})\\s*(?i:(ya?ml))\\s*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "contentName": "source.embedded.yaml", + "patterns": [ + { + "include": "#block-callout" + }, + { + "include": "source.yaml" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + }, + { + "name": "markup.raw.asciidoc", + "begin": "^\\s*(`{3,}).*$", + "beginCaptures": { + "0": { + "name": "support.asciidoc" + } + }, + "patterns": [ + { + "include": "#block-callout" + } + ], + "end": "^\\s*\\1\\s*$", + "endCaptures": { + "0": { + "name": "support.asciidoc" + } + } + } + ] + } + } } \ No newline at end of file diff --git a/com.vogella.ide.editor.asciidoc/syntaxes/asciidoc.tmLanguage b/com.vogella.ide.editor.asciidoc/syntaxes/asciidoc.tmLanguage deleted file mode 100644 index b7eff46..0000000 --- a/com.vogella.ide.editor.asciidoc/syntaxes/asciidoc.tmLanguage +++ /dev/null @@ -1,2355 +0,0 @@ - - - - - fileTypes - - asciidoc - - keyEquivalent - ^~A - name - AsciiDoc - patterns - - - include - #lists - - - include - #blocks - - - include - #titles - - - include - #lines - - - include - #inline - - - include - #characters - - - repository - - blocks - - patterns - - - include - #literal_block_announced - - - include - #literal_block_delimited - - - include - #comment_block - - - include - #listing_block - - - include - #sidebar_block - - - include - #passthrough_block - - - include - #quote_block - - - include - #example_block - - - include - #open_block - - - repository - - comment_block - - begin - ^(/{4,})\s*$\n? - beginCaptures - - 0 - - name - punctuation.definition.comment.begin.asciidoc - - - comment - comment block; note the big surprise that macros are enabled here - contentName - meta.block.comment.content.asciidoc - end - ^(/{4,})\s*$\n? - endCaptures - - 0 - - name - punctuation.definition.comment.end.asciidoc - - - name - comment.block.asciidoc - patterns - - - include - #macro - - - - example_block - - begin - ^(={4,5})\s*$\n? - beginCaptures - - 0 - - name - constant.delimiter.example.begin.asciidoc - - - comment - might need to add more includes but these are the ones that arise in practice for me; note restriction to 4 or 5 to distinguish from level 0 setext - contentName - meta.block.example.content.asciidoc - end - ^(={4,5})\s*$\n? - endCaptures - - 0 - - name - constant.delimiter.example.end.asciidoc - - - name - string.unquoted.block.example.asciidoc - patterns - - - include - #lists - - - include - #listing_block - - - include - #lines - - - include - #inline - - - include - #characters - - - - listing_block - - begin - ^(\-{4,5})\s*$\n? - beginCaptures - - 0 - - name - constant.delimiter.listing.begin.asciidoc - - - comment - declare content as source in order to get any extra yummy source goodness - contentName - source.block.listing.content.asciidoc - end - ^(\-{4,5})\s*$\n? - endCaptures - - 0 - - name - constant.delimiter.listing.end.asciidoc - - - name - meta.embedded.block.listing.asciidoc - patterns - - - include - #callout - - - - literal_block_announced - - begin - ^((\[)"?literal\"?,?.*(\]))\s*$\n? - beginCaptures - - 1 - - name - support.variable.attributelist.asciidoc - - 2 - - name - punctuation.definition.attributelistline.begin.asciidoc - - 3 - - name - punctuation.definition.attributelistline.end.asciidoc - - - comment - section template announced as literal, starts literal block - contentName - meta.block.literal.content.asciidoc - end - (?=^\s*$) - name - string.literal.block.announced.asciidoc - patterns - - - include - #callout - - - - literal_block_delimited - - begin - ^(\.{4,})\s*$\n? - beginCaptures - - 0 - - name - constant.delimiter.block.literal.begin.asciidoc - - - comment - alternate way to get literal block, delimit with 4 or more periods - contentName - meta.block.literal.content.asciidoc - end - ^(\.{4,})\s*$\n? - endCaptures - - 0 - - name - constant.delimiter.block.literal.end.asciidoc - - - name - string.literal.block.delimited.asciidoc - patterns - - - include - #callout - - - - open_block - - begin - ^(\-\-)\s*$\n? - beginCaptures - - 0 - - name - constant.delimiter.block.open.begin.asciidoc - - - comment - might need to check on these includes - contentName - meta.block.open.content.asciidoc - end - ^(\-\-)\s*$\n? - endCaptures - - 0 - - name - constant.delimiter.block.open.end.asciidoc - - - name - meta.block.open.asciidoc - patterns - - - include - #lists - - - include - #comment_block - - - include - #listing_block - - - include - #passthrough_block - - - include - #lines - - - include - #inline - - - include - #characters - - - - passthrough_block - - begin - ^(\+{4,5})\s*$\n? - beginCaptures - - 0 - - name - constant.delimiter.block.passthrough.begin.asciidoc - - - comment - must be four or five to distinguish from level 4 setext - contentName - text.xml.block.passthrough.content.asciidoc - end - ^(\+{4,5})\s*$\n? - endCaptures - - 0 - - name - constant.delimiter.block.passthrough.end.asciidoc - - - name - meta.embedded.block.passthrough.asciidoc - patterns - - - include - text.xml - - - - quote_block - - begin - ^(_{4,})\s*$\n? - beginCaptures - - 0 - - name - constant.delimiter.block.quote.begin.asciidoc - - - comment - might need to add more includes, but these are the ones that arise for me in practice - contentName - meta.block.quote.content.asciidoc - end - ^(_{4,})\s*$\n? - endCaptures - - 0 - - name - constant.delimiter.block.quote.end.asciidoc - - - name - markup.quote.block.asciidoc - patterns - - - include - #lines - - - include - #inline - - - include - #characters - - - - sidebar_block - - begin - ^(\*{4,})\s*$\n? - beginCaptures - - 0 - - name - constant.delimiter.block.sidebar.begin.asciidoc - - - comment - might need to add more includes but these are the ones that arise in practice for me - contentName - meta.block.sidebar.content.asciidoc - end - ^(\*{4,})\s*$\n? - endCaptures - - 0 - - name - constant.delimiter.block.sidebar.end.asciidoc - - - name - string.quoted.block.sidebar.asciidoc - patterns - - - include - #lists - - - include - #comment_block - - - include - #listing_block - - - include - #lines - - - include - #inline - - - include - #characters - - - - - - callout - - captures - - 1 - - name - punctuation.definition.callout.begin.asciidoc - - 2 - - name - punctuation.definition.callout.end.asciidoc - - - comment - has to be alone in repository (not in a group), as it operates in only a couple of highly specific places - match - (?<!\\)(<)\d+(>) - name - constant.other.callout.asciidoc - - characters - - patterns - - - include - #entity - - - include - #xmlentity - - - include - #escape - - - include - #replacement - - - include - #passmacro - - - include - #macro - - - include - #xref - - - include - #biblio_anchor - - - include - #index3 - - - include - #index2 - - - repository - - biblio_anchor - - captures - - 1 - - name - punctuation.definition.biblioanchor.begin.asciidoc - - 2 - - name - punctuation.definition.biblioanchor.end.asciidoc - - - match - (?<!\[)(\[\[\[).*?(\]\]\])(?!\]) - name - storage.type.reference.biblioanchor.asciidoc - - entity - - comment - &#x278a; &#182; - match - (?<!\\)&#(x[0-9a-fA-f]{4}|[0-9]{3}); - name - constant.character.entity.asciidoc - - escape - - comment - I do not really know if this is a good list, adopted wholesale from original bundle - match - \\(?=[-`*_#+.!(){}\[\]\\>:]) - name - constant.character.escape.asciidoc - - index2 - - captures - - 1 - - name - constant.character.indexterm.double.begin.asciidoc - - 3 - - name - constant.character.indexterm.double.end.asciidoc - - - match - (?<!\()(\({2})([^\(\s].*?)(\){2})(?!\)) - name - variable.other.indexterm.double.asciidoc - - index3 - - captures - - 1 - - name - constant.character.indexterm.triple.begin.asciidoc - - 3 - - name - constant.character.indexterm.triple.end.asciidoc - - - match - (?<!\()(\({3})([^\(].*?)(\){3})(?!\)) - name - variable.other.indexterm.triple.asciidoc - - macro - - captures - - 1 - - name - markup.underline.link.macro.asciidoc - - 3 - - name - keyword.control.name.macro.asciidoc - - 4 - - name - constant.character.separator.macro.asciidoc - - 5 - - name - markup.underline.target.macro.asciidoc - - 6 - - name - constant.character.attributes.macro.begin.asciidoc - - 7 - - name - variable.parameter.attributes.macro.asciidoc - - 8 - - name - constant.character.attributes.macro.end.asciidoc - - - comment - there are other macro notations but I match only those that end in square brackets - match - (?x) - (?: - ((?:https?|mailto|ftp|file) # specify separately so we can mark them as links that TextMate opens - ?:{1} # inline only - \S*) # (others such as image are partial URLs and/or TextMate cannot handle them) - | - (([a-zA-Z0-9][a-zA-Z0-9_]*) - (:{1,2}) - (\S*)) - ) - (?:(\[)([^\]]*)(\])) - - name - meta.macro.asciidoc - - passmacro - - captures - - 1 - - name - keyword.control.name.macro.pass.asciidoc - - 2 - - name - constant.character.separator.macro.asciidoc - - 3 - - name - markup.underline.target.macro.asciidoc - - 4 - - name - constant.character.attributes.macro.begin.asciidoc - - 5 - - name - variable.parameter.attributes.macro.pass.asciidoc - patterns - - - include - text.xml - - - - 6 - - name - constant.character.attributes.macro.end.asciidoc - - - match - (?x) - (pass) - (:{1,2}) - (\S*) - (\[)([^\]]*)(\]) - - name - meta.macro.pass.asciidoc - - replacement - - comment - replace me, my sweet replaceable you... - match - (?x) - (?<!\\) # unless I am preceded by an escape, that is... - ( - \(C\) - | - \(TM\) - | - \(R\) - | - ((?<!\-)\-\-(?!\-)) # exactly two, and even this may not rule out all that I want to - | - ((?<!\.)\.\.\.(?!\.)) # exactly three - | - \-> - | - <\- - | - => - | - <= - ) - name - constant.character.replacement.asciidoc - - xmlentity - - comment - amp, lt, gt - match - (?<!\\)&(amp|lt|gt); - name - constant.character.entity.xml.asciidoc - - xref - - captures - - 1 - - name - constant.character.xref.begin.asciidoc - - 2 - - name - markup.underline.term.xref.asciidoc - - 5 - - name - variable.parameter.xref.asciidoc - - 6 - - name - constant.character.xref.end.asciidoc - - - match - (?<!<)(<<)([^,]*?)((,\s*)(.*?))?(>>)(?!<) - name - meta.xref.asciidoc - - - - inline - - patterns - - - include - #passthru - - - include - #double_bold - - - include - #double_italic - - - include - #double_literal - - - include - #double_unquoted - - - include - #double_quote - - - include - #single_bold - - - include - #single_italic - - - include - #single_literal - - - include - #single_literal_nopassthru - - - include - #single_unquoted - - - include - #superscript - - - include - #subscript - - - repository - - double_bold - - captures - - attlist - - name - support.variable.attributelist.asciidoc - - closer - - name - punctuation.definition.bold.double.end.asciidoc - - delim - - name - punctuation.definition.bold.double.begin.asciidoc - - inner - - name - meta.boldinner.double.asciidoc - patterns - - - include - #double_italic - - - include - #double_literal - - - include - #double_unquoted - - - include - #double_quote - - - include - #single_italic - - - include - #single_literal - - - include - #single_literal_nopassthru - - - include - #single_unquoted - - - include - #superscript - - - include - #subscript - - - include - #characters - - - - - match - (?x) - (?<attlist>\[[^\]]*?\])? # might start with an attribute list - (?<!\\) # must not be preceded by escape - (?<delim>\*\*)(?<inner>.*?)(?<closer>\k<delim>) # anything surrounded by double star - - name - markup.bold.double.asciidoc - - double_italic - - captures - - attlist - - name - support.variable.attributelist.asciidoc - - closer - - name - punctuation.definition.italic.double.end.asciidoc - - delim - - name - punctuation.definition.italic.double.begin.asciidoc - - inner - - name - meta.italicinner.double.asciidoc - patterns - - - include - #double_bold - - - include - #double_literal - - - include - #double_unquoted - - - include - #double_quote - - - include - #single_bold - - - include - #single_literal - - - include - #single_literal_nopassthru - - - include - #single_unquoted - - - include - #superscript - - - include - #subscript - - - include - #characters - - - - - match - (?x) - (?<attlist>\[[^\]]*?\])? # might start with attribute list - (?<!\\) # must not be preceded by escape - (?<delim>__)(?<inner>.*?)(?<closer>\k<delim>) # anything surrounded by double underline - - name - markup.italic.double.asciidoc - - double_literal - - captures - - attlist - - name - support.variable.attributelist.asciidoc - - closer - - name - punctuation.definition.literal.double.end.asciidoc - - delim - - name - punctuation.definition.literal.double.begin.asciidoc - - inner - - name - meta.literalinner.double.asciidoc - patterns - - - include - #double_bold - - - include - #double_italic - - - include - #double_unquoted - - - include - #double_quote - - - include - #single_bold - - - include - #single_italic - - - include - #single_literal_nopassthru - - - include - #single_unquoted - - - include - #superscript - - - include - #subscript - - - include - #characters - - - - - match - (?x) - (?<attlist>\[[^\]]*?\])? # might start with attribute list - (?<!\\) # must not be preceded by escape - (?<delim>\+\+)(?<inner>.*?)(?<closer>\k<delim>) # anything surrounded by double plus - - name - string.other.literal.double.asciidoc - - double_quote - - captures - - attlist - - name - support.variable.attributelist.asciidoc - - closer - - name - punctuation.definition.string.quoted.double.end.asciidoc - - delim - - name - punctuation.definition.string.quoted.double.begin.asciidoc - - inner - - name - meta.doublequotedinner.asciidoc - patterns - - - include - #double_bold - - - include - #double_italic - - - include - #double_literal - - - include - #double_unquoted - - - include - #single_bold - - - include - #single_italic - - - include - #single_literal - - - include - #single_literal_nopassthru - - - include - #single_unquoted - - - include - #superscript - - - include - #subscript - - - include - #characters - - - - - match - (?x) - (?<attlist>\[[^\]]*?\])? # might start with attribute list - (?<!\w|\\) # cannot be preceded by word character or escape - (?<delim>``)(?<inner>(?!\s).*?(?<!\s))(?<closer>'') # double backtick followed by non-space, anything, double-apostrophe preceded by non-space - (?!\w) # cannot be followed by word character either - - name - string.quoted.double.asciidoc - - double_unquoted - - captures - - attlist - - name - support.variable.attributelist.asciidoc - - closer - - name - punctuation.definition.string.unquoted.double.end.asciidoc - - delim - - name - punctuation.definition.string.unquoted.double.begin.asciidoc - - inner - - name - string.unquoted.unquotedinner.double.asciidoc - patterns - - - include - #double_bold - - - include - #double_italic - - - include - #double_literal - - - include - #double_quote - - - include - #single_bold - - - include - #single_italic - - - include - #single_literal - - - include - #single_literal_nopassthru - - - include - #superscript - - - include - #subscript - - - include - #characters - - - - - match - (?x) - (?<attlist>\[[^\]]*?\])? # might start with an attribute list (indeed, that is its purpose) - (?<!\\) # must not be preceded by escape - (?<delim>\#\#)(?<inner>.*?)(?<closer>\k<delim>) # anything surrounded by double hashes - - name - string.other.unquoted.double.asciidoc - - passthru - - captures - - 1 - - name - constant.character.passthru.begin.asciidoc - - 2 - - name - variable.parameter.passthruinner.asciidoc - patterns - - - include - text.xml - - - - 3 - - name - constant.character.passthru.end.asciidoc - - - comment - must be dead first among the inlines, so as to take priority - match - (\+\+\+|\$\$)(.*?)(\1) - name - meta.passthru.inline.asciidoc - - single_bold - - captures - - attlist - - name - support.variable.attributelist.asciidoc - - closer - - name - punctuation.definition.bold.single.end.asciidoc - - delim - - name - punctuation.definition.bold.single.begin.asciidoc - - inner - - name - meta.boldinner.single.asciidoc - patterns - - - include - #double_italic - - - include - #double_literal - - - include - #double_unquoted - - - include - #double_quote - - - include - #single_italic - - - include - #single_literal - - - include - #single_literal_nopassthru - - - include - #single_unquoted - - - include - #superscript - - - include - #subscript - - - include - #characters - - - - - match - (?x) - (?<attlist>\[[^\]]*?\])? # might start with an attributes list - (?<=^|\W)(?<!\\) # must be preceded by a nonword character, and not by an escape - (?<delim>\*)(?<inner>(?!\s).*?(?<!\s))(?<closer>\k<delim>) # delimiter *, no space, anything, no space, delimiter... - (?!\w) # ... and must be followed by nonword character - - name - markup.bold.single.asciidoc - - single_italic - - captures - - attlist - - name - support.variable.attributelist.asciidoc - - closer - - name - punctuation.definition.italic.single.end.asciidoc - - delim - - name - punctuation.definition.italic.single.begin.asciidoc - - inner - - name - meta.italicinner.single.asciidoc - patterns - - - include - #double_bold - - - include - #double_literal - - - include - #double_unquoted - - - include - #double_quote - - - include - #single_bold - - - include - #single_literal - - - include - #single_literal_nopassthru - - - include - #single_unquoted - - - include - #superscript - - - include - #subscript - - - include - #characters - - - - - match - (?x) - (?<attlist>\[[^\]]*?\])? # might be preceded by an attributes list - (?<=^|\W)(?<!\\) # must be preceded by a nonword character, and not by an escape - (?<delim>_)(?<inner>(?!\s).*?(?<!\s))(?<closer>\k<delim>) # delimiter underscore, nonspace, anything, nonspace, delimiter - (?!\w) # and must by followed by nonword character - - name - markup.italic.single.asciidoc - - single_literal - - captures - - attlist - - name - support.variable.attributelist.asciidoc - - closer - - name - punctuation.definition.literal.single.end.asciidoc - - delim - - name - punctuation.definition.literal.single.begin.asciidoc - - inner - - name - meta.literalinner.single.asciidoc - patterns - - - include - #double_bold - - - include - #double_italic - - - include - #double_unquoted - - - include - #double_quote - - - include - #single_bold - - - include - #single_italic - - - include - #single_literal_nopassthru - - - include - #single_unquoted - - - include - #superscript - - - include - #subscript - - - include - #characters - - - - - match - (?x) - (?<attlist>\[[^\]]*?\])? # might start with attributes list - (?<=^|\W)(?<!\\) # must be preceded by a nonword character, and not by escape - (?<delim>\+)(?<inner>(?!\s).*?(?<!\s))(?<closer>\k<delim>) # delimiter plus, nonspace, anything, nonspace, delimiter - (?!\w) # and must be followed by nonword character - - name - string.other.literal.single.asciidoc - - single_literal_nopassthru - - captures - - closer - - name - punctuation.definition.literal.single.nopassthru.end.asciidoc - - delim - - name - punctuation.definition.literal.single.nopassthru.begin.asciidoc - - inner - - name - meta.literalinner.single.nopassthru.asciidoc - - - match - (?x) - (?<!\w|\\) # must not be preceded by word character or escape - (?<delim>`)(?<inner>(?!\s).*?(?<!\s))(?<closer>\k<delim>) # delimiter backtick, nonspace, anything, nonspace, delimiter - (?!\w) # and must be followed by nonword character - - name - string.other.literal.nopassthru.asciidoc - - single_unquoted - - captures - - attlist - - name - support.variable.attributelist.asciidoc - - closer - - name - punctuation.definition.string.unquoted.single.end.asciidoc - - delim - - name - punctuation.definition.string.unquoted.single.begin.asciidoc - - inner - - name - string.unquoted.unquotedinner.single.asciidoc - patterns - - - include - #double_bold - - - include - #double_italic - - - include - #double_literal - - - include - #double_quote - - - include - #single_bold - - - include - #single_italic - - - include - #single_literal - - - include - #single_literal_nopassthru - - - include - #superscript - - - include - #subscript - - - include - #characters - - - - - match - (?x) - (?<attlist>\[[^\]]*?\])? # might start with attribute list (darned well better or why are we here) - (?<=^|\W)(?<!\\) # must be preceded by nonword character, and not by escape - (?<delim>\#)(?<inner>(?!\s).*?(?<!\s))(?<closer>\k<delim>) # delimiter hash, nonspace, anything, nonspace, delimiter - (?!\w) # and must be followed by nonword character - - name - string.other.unquoted.single.asciidoc - - subscript - - captures - - attlist - - name - support.variable.attributelist.asciidoc - - closer - - name - punctuation.definition.string.subscript.end.asciidoc - - delim - - name - punctuation.definition.string.subscript.begin.asciidoc - - inner - - name - meta.subscriptinner.asciidoc - patterns - - - include - #double_bold - - - include - #double_italic - - - include - #double_literal - - - include - #double_unquoted - - - include - #double_quote - - - include - #single_bold - - - include - #single_italic - - - include - #single_literal - - - include - #single_literal_nopassthru - - - include - #single_unquoted - - - include - #superscript - - - include - #characters - - - - - match - (?x) - (?<attlist>\[[^\]]*?\])? # might start with attribute list - (?<!\\) # must not be preceded by escape - (?<delim>~)(?<inner>.*?)(?<closer>\k<delim>) # twiddle anything twiddle - - name - string.other.subscript.asciidoc - - superscript - - captures - - attlist - - name - support.variable.attributelist.asciidoc - - closer - - name - punctuation.definition.string.superscript.end.asciidoc - - delim - - name - punctuation.definition.string.superscript.begin.asciidoc - - inner - - name - meta.superscriptinner.asciidoc - patterns - - - include - #double_bold - - - include - #double_italic - - - include - #double_literal - - - include - #double_unquoted - - - include - #double_quote - - - include - #single_bold - - - include - #single_italic - - - include - #single_literal - - - include - #single_literal_nopassthru - - - include - #single_unquoted - - - include - #subscript - - - include - #characters - - - - - match - (?x) - (?<attlist>\[[^\]]*?\])? # might start with attribute list - (?<!\\) # no preceding escape - (?<delim>\^)(?<inner>.*?)(?<closer>\k<delim>) # caret anything caret - - name - string.other.superscript.asciidoc - - - - lines - - patterns - - - include - #comment - - - include - #list_continuation - - - include - #linebreak - - - include - #pagebreak - - - include - #ruler - - - include - #block_heading - - - include - #block_id - - - include - #section_template - - - include - #attribute_list_line - - - include - #attribute_entry - - - repository - - attribute_entry - - captures - - attrname - - name - support.variable.attribute.asciidoc - - attrvalue - - name - meta.attributeentry.value.asciidoc - patterns - - - include - #characters - - - - closer - - name - punctuation.definition.attributeentry.attrname.end.asciidoc - - delim - - name - punctuation.definition.attributeentry.attrname.begin.asciidoc - - - match - ^(?<attrname>(?<delim>:)(\w[^.]*?)(\.(.*?))?(?<closer>:))(\s+(?<attrvalue>.*))?$\n? - name - meta.attributeentry.asciidoc - - attribute_list_line - - captures - - 1 - - name - punctuation.definition.attributelistline.begin.asciidoc - - 2 - - name - punctuation.definition.attributelistline.end.asciidoc - - - comment - Attribute list as paragraph: single brackets. No need for special treatment of escape; follows literal block, section template as being a more general regex - match - ^(\[)[^\[\]]*(\])\s*$\n? - name - support.variable.attributelist.asciidoc - - block_heading - - captures - - 1 - - name - punctuation.definition.blockheading.asciidoc - - - comment - A line beginning with a period and no space - match - ^(\.)\w.*$\n? - name - markup.heading.block.asciidoc - - block_id - - captures - - 1 - - name - punctuation.definition.blockid.begin.asciidoc - - 2 - - name - markup.underline.blockid.id.asciidoc - - 3 - - name - punctuation.definition.blockid.end.asciidoc - - - comment - A line surrounded by double square brackets - match - ^(\[\[)([^\[].*)(\]\])\s*$\n? - name - meta.tag.blockid.asciidoc - - comment - - captures - - 1 - - name - punctuation.definition.comment.line.asciidoc - - 2 - - name - meta.line.comment.content.asciidoc - - - match - ^(//)([^/\n].*|)$\n? - name - comment.line.double-slash.asciidoc - - linebreak - - match - (?<=\s)\+$\n? - name - constant.linebreak.asciidoc - - list_continuation - - match - ^\+\s*$\n? - name - constant.listcontinuation.asciidoc - - pagebreak - - match - ^<{3,}$\n? - name - meta.separator.pagebreak.asciidoc - - ruler - - match - ^'{3,}$\n? - name - meta.separator.ruler.asciidoc - - section_template - - captures - - 1 - - name - punctuation.definition.sectiontemplate.begin.asciidoc - - 4 - - name - meta.tag.sectiontemplate.asciidoc - - 6 - - name - punctuation.definition.sectiontemplate.end.asciidoc - - 7 - - name - punctuation.definition.sectiontemplate.end.asciidoc - - - comment - fixed list of known template names - match - (?x)^ - (\[) # in square brackets - (template\s*=\s*)?(")? # might start with template-equals and might have template name in quotes - ( - sect\d|abstract|preface|colophon|dedication|glossary|bibliography|synopsis|appendix|index # fixed list of known templates - ) - (".*(\])|(\])) # either close the quote (and perhaps go on) and close the bracket, or close the bracket immediately - \s*$\n? - name - variable.parameter.sectiontemplate.asciidoc - - - - lists - - comment - My strategy for lists (and similar) is not to try to treat entire paragraphs as lists, but only call out the opening - patterns - - - include - #admonition_word - - - include - #bulleted_list - - - include - #numbered_list_dotted - - - include - #numbered_list_numeric - - - include - #numbered_list_roman - - - include - #labeled_list - - - include - #labeled_list_semicolons - - - include - #callout_list - - - repository - - admonition_word - - comment - NOTE:, TIP:, IMPORTANT:, WARNING: or CAUTION: - match - ^(NOTE|TIP|IMPORTANT|WARNING|CAUTION):(?=\s+) - name - support.constant.admonitionword.asciidoc - - bulleted_list - - captures - - 1 - - name - string.unquoted.list.bullet.asciidoc - - 2 - - name - constant.numeric.list.bullet.asciidoc - - - match - ^(\s*(\-|\*{1,5}))\s+(?=\w) - name - markup.list.bulleted.asciidoc - - callout_list - - captures - - 1 - - name - string.unquoted.list.callout.asciidoc - - 2 - - name - constant.numeric.callout.asciidoc - - 3 - - name - punctuation.definition.calloutlistnumber.begin.asciidoc - - 4 - - name - punctuation.definition.calloutlistnumber.end.asciidoc - - - match - ^(\s*((<)\d+?(>)))\s+(?=\w) - name - markup.list.numbered.callout.asciidoc - - labeled_list - - captures - - 1 - - name - meta.list.label.asciidoc - patterns - - - include - #inline - - - include - #characters - - - - 2 - - name - constant.labeledlist.separator.asciidoc - - - match - ^\s*(.*)(?<!:)(:{2,4})(\s|$\n?) - name - markup.list.labeled.asciidoc - - labeled_list_semicolons - - captures - - 1 - - name - meta.list.label.asciidoc - patterns - - - include - #inline - - - include - #characters - - - - 2 - - name - constant.labeledlist.separator.asciidoc - - - match - ^\s*(.*)(?<!;)(;{2})(\s|$\n?) - name - markup.list.labeled.semicolons.asciidoc - - numbered_list_dotted - - captures - - 1 - - name - string.unquoted.list.dotted.asciidoc - - 2 - - name - constant.numeric.list.dot.asciidoc - - - comment - The space distinguishes it from a block title - match - ^(\s*(\.{1,5}))\s+(?=\w) - name - markup.list.numbered.dotted.asciidoc - - numbered_list_numeric - - captures - - 1 - - name - string.unquoted.list.numeric.asciidoc - - 2 - - name - constant.numeric.list.number.asciidoc - - - match - ^(\s*([1-9a-zA-Z][0-9]*\.))\s+(?=\w) - name - markup.list.numbered.numeric.asciidoc - - numbered_list_roman - - captures - - 1 - - name - string.unquoted.list.roman.asciidoc - - 2 - - name - constant.numeric.list.romannumeral.asciidoc - - - match - ^(\s*([ivxIVX]+\)))\s+(?=\w) - name - markup.list.numbered.roman.asciidoc - - - - titles - - patterns - - - include - #setext_title - - - include - #level_title - - - repository - - level_title - - captures - - eq - - name - punctuation.definition.heading.asciidoc - - title - - name - entity.name.section.asciidoc - - - match - ^(?<eq>={1,5}) (?<title>\w.*)$\n? - name - markup.heading.level.${eq/=(?<two>=)?(?<three>=)?(?<four>=)?(?<five>=)?/${five:?4:${four:?3:${three:?2:${two:?1:0}}}}/}.asciidoc - - setext_title - - comment - Alas, all we can do is mark the second line; TextMate cannot do double-line patterns - match - ^(=|-|~|\^|\+){6,}\s*$\n? - name - markup.heading.setext.n.asciidoc - - - - - uuid - 961C6043-B725-4E2D-83E8-114BF3A7389D - - \ No newline at end of file