Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions vscode/language-configuration.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
{
"comments": {
"lineComment": "--"
},
// symbols used as brackets
"brackets": [
["(", ")"]
],
// symbols that are auto closed when typing
"autoClosingPairs": [
["(", ")"],
["\"", "\""]
],
// symbols that that can be used to surround a selection
"surroundingPairs": [
["(", ")"],
["'", "'"]
]
}
26 changes: 26 additions & 0 deletions vscode/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
{
"name": "sbvr",
"displayName": "sbvr",
"description": "SBVR highlighting",
"version": "0.0.1",
"publisher": "pjgazzard",
"engines": {
"vscode": "^1.16.0"
},
"categories": [
"Languages"
],
"contributes": {
"languages": [{
"id": "sbvr",
"aliases": ["sbvr", "sbvr"],
"extensions": [".sbvr"],
"configuration": "./language-configuration.json"
}],
"grammars": [{
"language": "sbvr",
"scopeName": "source.sbvr",
"path": "./syntaxes/sbvr.tmLanguage.json"
}]
}
}
35 changes: 35 additions & 0 deletions vscode/syntaxes/sbvr.tmLanguage.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
{
"$schema": "https://raw.githubusercontent.com/martinring/tmlanguage/master/tmlanguage.json",
"name": "sbvr",
"patterns": [
{
"include": "#keywords"
},
{
"include": "#strings"
}
],
"repository": {
"keywords": {
"patterns": [{
"name": "storage.type.sbvr",
"match": "^\\s*(Vocabulary|Term|Name|Fact type|Rule Name|Synonym|Synonymous Form|Term Form):"
}, {
"name": "keyword.control.sbvr",
"match": "^\\s*(Rule|Concept Type|Definition|Definition (Informal)|Description|Dictionary Basis|Example|Enforcement Level|General Concept|Guidance Type|Namespace URI|Necessity|Note|Possibility|Reference Scheme|See|Source|Subject Field|Synonymous Statement):"
}]
},
"strings": {
"name": "string.quoted.double.sbvr",
"begin": "\"",
"end": "\"",
"patterns": [
{
"name": "constant.character.escape.sbvr",
"match": "\\\\."
}
]
}
},
"scopeName": "source.sbvr"
}