{ "fileTypes": [ "apib" ], "foldingStartMarker": "(?x)\n (<(?i:head|body|table|thead|tbody|tfoot|tr|div|select|fieldset|style|script|ul|ol|form|dl)\\b.*?>\n |)\n |\\{\\s*($|\\?>\\s*$|//|/\\*(.*\\*/\\s*$|(?!.*?\\*/)))\n )", "foldingStopMarker": "(?x)\n (\n |^\\s*-->\n |(^|\\s)\\}\n )", "keyEquivalent": "^~M", "name": "API Blueprint", "patterns": [ { "include": "#blueprint_group" }, { "include": "#blueprint_data_structures" }, { "include": "#blueprint_action" }, { "include": "#blueprint_resource" }, { "include": "#blueprint_shorthand" }, { "name": "blueprint.response.json", "begin": "([-+*]) ([Rr]equest|[Rr]esponse) (\\d+)?(?: (\\(.*\\/+json(?:[ ;\\/]+.*)?\\)))+", "end": "^(?=\\S)", "beginCaptures": { "1": { "name": "variable.unordered.list.gfm" }, "3": { "name": "constant.numeric" }, "4": { "name": "variable.language.fenced.markdown" } }, "patterns": [ { "include": "#http-headers" }, { "include": "#mson-block" }, { "begin": "([-+*]) [Bb]ody", "end": "^(?=(?=\\S)|(?=\\s+\\+))", "beginCaptures": { "1": { "name": "variable.unordered.list.gfm" } }, "patterns": [ { "include": "source.js" } ] }, { "include": "#response-unstyled-section" }, { "include": "source.js" } ] }, { "name": "blueprint.response.xml", "begin": "([-+*]) ([Rr]equest|[Rr]esponse) (\\d+)?(?: (\\(.*\\/+xml(?:[ ;\\/]+.*)?\\)))+", "end": "^(?=\\S)", "beginCaptures": { "1": { "name": "variable.unordered.list.gfm" }, "3": { "name": "constant.numeric" }, "4": { "name": "variable.language.fenced.markdown" } }, "patterns": [ { "include": "#http-headers" }, { "include": "#mson-block" }, { "begin": "([-+*]) [Bb]ody", "end": "^(?=(?=\\S)|(?=\\s+\\+))", "beginCaptures": { "1": { "name": "variable.unordered.list.gfm" } }, "patterns": [ { "include": "text.xml" } ] }, { "include": "#response-unstyled-section" }, { "include": "text.xml" } ] }, { "name": "blueprint.response", "begin": "([-+*]) ([Rr]equest|[Rr]esponse) ?(\\d+)?(?: (\\(.*\\))+)?", "end": "^(?=\\S)", "beginCaptures": { "1": { "name": "variable.unordered.list.gfm" }, "3": { "name": "constant.numeric" }, "4": { "name": "variable.language.fenced.markdown" } }, "patterns": [ { "include": "#http-headers" }, { "include": "#mson-block" }, { "include": "#response-unstyled-section" } ] }, { "include": "#mson-block" }, { "include": "#gfm" } ], "repository": { "blueprint_group": { "match": "^#{1,6} [Gg]roup.*\\n?", "name": "markup.heading.markdown punctuation.definition.heading.markdown" }, "blueprint_resource": { "match": "^#{1,6} .*\\[(.*)\\]\\n?", "name": "markup.heading.markdown punctuation.definition.heading.markdown", "captures": { "1": { "name": "meta.link.inet.markdown markup.underline.link.markdown" } } }, "blueprint_action": { "match": "^#{1,6} .*\\[(HEAD|GET|PUT|POST|PATCH|DELETE)(.*)\\]\\n?", "name": "markup.heading.markdown punctuation.definition.heading.markdown", "captures": { "1": { "name": "markup.quote" }, "2": { "name": "meta.link.inet.markdown markup.underline.link.markdown" } } }, "blueprint_data_structures": { "begin": "^(#{1,6} [Dd]ata [Ss]tructures)", "end": "^(?=#\\s)", "captures": { "1": { "name": "markup.heading.markdown punctuation.definition.heading.markdown" } }, "patterns": [ { "include": "text.html.markdown.source.gfm.mson" } ] }, "blueprint_shorthand": { "match": "^#{1,6} (HEAD|GET|PUT|POST|PATCH|DELETE) (.*)\\n?", "name": "markup.heading.markdown punctuation.definition.heading.markdown", "captures": { "2": { "name": "meta.link.inet.markdown markup.underline.link.markdown" } } }, "http-headers": { "begin": "([-+*]) [Hh]eaders", "end": "^(?=(?=\\S)|(?=\\s+\\+))", "beginCaptures": { "1": { "name": "variable.unordered.list.gfm" } }, "patterns": [ { "match": "(.*?):(.*)", "captures": { "1": { "name": "keyword" }, "2": { "name": "header-value" } } } ] }, "mson-block": { "patterns": [ { "begin": "^([-+*]) ([Aa]ttributes|[Pp]arameters)", "end": "^(?=\\S)", "beginCaptures": { "1": { "name": "variable.unordered.list.gfm" } }, "name": "mson-block", "patterns": [ { "include": "text.html.markdown.source.gfm.mson" } ] }, { "begin": "^(\\s+)([-+*]) ([Aa]ttributes|[Pp]arameters)", "end": "^(?!\\1|\\n)|(?=\\1[-+*])", "beginCaptures": { "2": { "name": "variable.unordered.list.gfm" } }, "name": "mson-block", "patterns": [ { "include": "text.html.markdown.source.gfm.mson" } ] } ] }, "response-unstyled-section": { "comment": "Ignores list items that aren't the previously matched headers or body", "begin": "([-+*])", "end": "^(?=(?=\\S)|(?=\\s+[-+*]))", "beginCaptures": { "1": { "name": "variable.unordered.list.gfm" } } }, "gfm": { "patterns": [ { "match": "\\\\.", "name": "constant.character.escape.gfm" }, { "begin": "(?<=^|[^\\w\\d\\*])\\*\\*\\*(?!$|\\*|\\s)", "end": "(?]+)>", "name": "link", "captures": { "1": { "name": "punctuation.definition.begin.gfm" }, "2": { "name": "entity.gfm" }, "3": { "name": "punctuation.definition.end.gfm" }, "4": { "name": "markup.underline.link.gfm" } } }, { "match": "^\\s*(\\[)([^\\]]+)(\\])\\s*(:)\\s*(\\S+)", "name": "link", "captures": { "1": { "name": "punctuation.definition.begin.gfm" }, "2": { "name": "entity.gfm" }, "3": { "name": "punctuation.definition.end.gfm" }, "4": { "name": "punctuation.separator.key-value.gfm" }, "5": { "name": "markup.underline.link.gfm" } } }, { "match": "^\\s*([*+-])[ \\t]+", "captures": { "1": { "name": "variable.unordered.list.gfm" } } }, { "match": "^\\s*(\\d+\\.)[ \\t]+", "captures": { "1": { "name": "variable.ordered.list.gfm" } } }, { "begin": "^\\s*(>)", "end": "^\\s*?$", "beginCaptures": { "1": { "name": "support.quote.gfm" } }, "name": "comment.quote.gfm", "patterns": [ { "include": "$self" } ] }, { "match": "(?<=^|\\s|\"|'|\\(|\\[)(@)(\\w[-\\w:]*)(?=[\\s\"'.,;\\)\\]])", "captures": { "1": { "name": "variable.mention.gfm" }, "2": { "name": "string.username.gfm" } } }, { "match": "(?<=^|\\s|\"|'|\\(|\\[)(#)(\\d+)(?=[\\s\"'\\.,;\\)\\]])", "captures": { "1": { "name": "variable.issue.tag.gfm" }, "2": { "name": "string.issue.number.gfm" } } }, { "match": "( )$", "captures": { "1": { "name": "linebreak.gfm" } } }, { "begin": "