proschi 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +33 -0
- package/dist/cli.cjs +957 -0
- package/dist/server.cjs +11223 -0
- package/grammar/proschi.tmLanguage.json +236 -0
- package/package.json +56 -0
- package/schema/proschi-diagram.schema.json +512 -0
|
@@ -0,0 +1,236 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://raw.githubusercontent.com/martinring/tmlanguage/master/tmlanguage.json",
|
|
3
|
+
"name": "Proschi",
|
|
4
|
+
"scopeName": "source.proschi",
|
|
5
|
+
"fileTypes": [
|
|
6
|
+
"proschi"
|
|
7
|
+
],
|
|
8
|
+
"patterns": [
|
|
9
|
+
{
|
|
10
|
+
"include": "#comment"
|
|
11
|
+
},
|
|
12
|
+
{
|
|
13
|
+
"include": "#label"
|
|
14
|
+
},
|
|
15
|
+
{
|
|
16
|
+
"include": "#keyword"
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
"include": "#string"
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
"include": "#tech"
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
"include": "#team"
|
|
26
|
+
},
|
|
27
|
+
{
|
|
28
|
+
"include": "#arrow"
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
"include": "#position"
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
"include": "#brace"
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
"include": "#identifier"
|
|
38
|
+
}
|
|
39
|
+
],
|
|
40
|
+
"repository": {
|
|
41
|
+
"comment": {
|
|
42
|
+
"name": "comment.line.number-sign.proschi",
|
|
43
|
+
"match": "(?:^|(?<=\\s))#.*$"
|
|
44
|
+
},
|
|
45
|
+
"keyword": {
|
|
46
|
+
"comment": "Statement keywords start a line, or follow } as in `} alt \"Next\" {`.",
|
|
47
|
+
"match": "^\\s*(?:(\\})\\s*)?(title|group|usecase|par|alt)\\b",
|
|
48
|
+
"captures": {
|
|
49
|
+
"1": {
|
|
50
|
+
"name": "punctuation.section.block.end.proschi"
|
|
51
|
+
},
|
|
52
|
+
"2": {
|
|
53
|
+
"name": "keyword.control.proschi"
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
},
|
|
57
|
+
"position": {
|
|
58
|
+
"match": "\\b(pos)\\s+(-?\\d+)\\s*(,)\\s*(-?\\d+)",
|
|
59
|
+
"captures": {
|
|
60
|
+
"1": {
|
|
61
|
+
"name": "keyword.other.pos.proschi"
|
|
62
|
+
},
|
|
63
|
+
"2": {
|
|
64
|
+
"name": "constant.numeric.proschi"
|
|
65
|
+
},
|
|
66
|
+
"3": {
|
|
67
|
+
"name": "punctuation.separator.comma.proschi"
|
|
68
|
+
},
|
|
69
|
+
"4": {
|
|
70
|
+
"name": "constant.numeric.proschi"
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
},
|
|
74
|
+
"string": {
|
|
75
|
+
"name": "string.quoted.double.proschi",
|
|
76
|
+
"begin": "\"",
|
|
77
|
+
"end": "\"|$",
|
|
78
|
+
"beginCaptures": {
|
|
79
|
+
"0": {
|
|
80
|
+
"name": "punctuation.definition.string.begin.proschi"
|
|
81
|
+
}
|
|
82
|
+
},
|
|
83
|
+
"endCaptures": {
|
|
84
|
+
"0": {
|
|
85
|
+
"name": "punctuation.definition.string.end.proschi"
|
|
86
|
+
}
|
|
87
|
+
},
|
|
88
|
+
"patterns": [
|
|
89
|
+
{
|
|
90
|
+
"name": "constant.character.escape.proschi",
|
|
91
|
+
"match": "\\\\."
|
|
92
|
+
}
|
|
93
|
+
]
|
|
94
|
+
},
|
|
95
|
+
"tech": {
|
|
96
|
+
"name": "entity.name.type.tech.proschi",
|
|
97
|
+
"match": "\\[[^\\]\\n]*\\]?"
|
|
98
|
+
},
|
|
99
|
+
"team": {
|
|
100
|
+
"name": "entity.other.attribute-name.team.proschi",
|
|
101
|
+
"match": "@[A-Za-z0-9_-]*"
|
|
102
|
+
},
|
|
103
|
+
"arrow": {
|
|
104
|
+
"name": "keyword.operator.arrow.proschi",
|
|
105
|
+
"match": "->>|-->|->|-x(?![A-Za-z0-9_])"
|
|
106
|
+
},
|
|
107
|
+
"brace": {
|
|
108
|
+
"name": "punctuation.section.block.proschi",
|
|
109
|
+
"match": "[{}]"
|
|
110
|
+
},
|
|
111
|
+
"identifier": {
|
|
112
|
+
"name": "variable.other.node.proschi",
|
|
113
|
+
"match": "[A-Za-z_][A-Za-z0-9_]*"
|
|
114
|
+
},
|
|
115
|
+
"label": {
|
|
116
|
+
"comment": "Everything after ':' on a connection or step line. A JSON payload may continue over several lines until its brackets balance.",
|
|
117
|
+
"name": "meta.label.proschi",
|
|
118
|
+
"begin": ":",
|
|
119
|
+
"end": "$",
|
|
120
|
+
"beginCaptures": {
|
|
121
|
+
"0": {
|
|
122
|
+
"name": "punctuation.separator.label.proschi"
|
|
123
|
+
}
|
|
124
|
+
},
|
|
125
|
+
"patterns": [
|
|
126
|
+
{
|
|
127
|
+
"include": "#comment"
|
|
128
|
+
},
|
|
129
|
+
{
|
|
130
|
+
"include": "#payload"
|
|
131
|
+
},
|
|
132
|
+
{
|
|
133
|
+
"match": "\\b(GET|POST|PUT|PATCH|DELETE|HEAD|OPTIONS)\\b(?:\\s+(\\S+))?",
|
|
134
|
+
"captures": {
|
|
135
|
+
"1": {
|
|
136
|
+
"name": "keyword.other.http-method.proschi"
|
|
137
|
+
},
|
|
138
|
+
"2": {
|
|
139
|
+
"name": "string.unquoted.endpoint.proschi"
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
},
|
|
143
|
+
{
|
|
144
|
+
"comment": "A leading three-digit number on a response is its status code.",
|
|
145
|
+
"match": "\\G\\s*([1-5]\\d\\d)\\b",
|
|
146
|
+
"captures": {
|
|
147
|
+
"1": {
|
|
148
|
+
"name": "constant.numeric.status.proschi"
|
|
149
|
+
}
|
|
150
|
+
}
|
|
151
|
+
},
|
|
152
|
+
{
|
|
153
|
+
"name": "storage.type.format.proschi",
|
|
154
|
+
"match": "\\b(json|xml|text)\\b"
|
|
155
|
+
},
|
|
156
|
+
{
|
|
157
|
+
"include": "#string"
|
|
158
|
+
}
|
|
159
|
+
]
|
|
160
|
+
},
|
|
161
|
+
"payload": {
|
|
162
|
+
"patterns": [
|
|
163
|
+
{
|
|
164
|
+
"name": "meta.structure.dictionary.proschi",
|
|
165
|
+
"begin": "\\{",
|
|
166
|
+
"end": "\\}",
|
|
167
|
+
"beginCaptures": {
|
|
168
|
+
"0": {
|
|
169
|
+
"name": "punctuation.definition.dictionary.begin.proschi"
|
|
170
|
+
}
|
|
171
|
+
},
|
|
172
|
+
"endCaptures": {
|
|
173
|
+
"0": {
|
|
174
|
+
"name": "punctuation.definition.dictionary.end.proschi"
|
|
175
|
+
}
|
|
176
|
+
},
|
|
177
|
+
"patterns": [
|
|
178
|
+
{
|
|
179
|
+
"include": "#json"
|
|
180
|
+
}
|
|
181
|
+
]
|
|
182
|
+
},
|
|
183
|
+
{
|
|
184
|
+
"name": "meta.structure.array.proschi",
|
|
185
|
+
"begin": "\\[",
|
|
186
|
+
"end": "\\]",
|
|
187
|
+
"beginCaptures": {
|
|
188
|
+
"0": {
|
|
189
|
+
"name": "punctuation.definition.array.begin.proschi"
|
|
190
|
+
}
|
|
191
|
+
},
|
|
192
|
+
"endCaptures": {
|
|
193
|
+
"0": {
|
|
194
|
+
"name": "punctuation.definition.array.end.proschi"
|
|
195
|
+
}
|
|
196
|
+
},
|
|
197
|
+
"patterns": [
|
|
198
|
+
{
|
|
199
|
+
"include": "#json"
|
|
200
|
+
}
|
|
201
|
+
]
|
|
202
|
+
}
|
|
203
|
+
]
|
|
204
|
+
},
|
|
205
|
+
"json": {
|
|
206
|
+
"patterns": [
|
|
207
|
+
{
|
|
208
|
+
"include": "#payload"
|
|
209
|
+
},
|
|
210
|
+
{
|
|
211
|
+
"name": "string.quoted.double.json.proschi",
|
|
212
|
+
"begin": "\"",
|
|
213
|
+
"end": "\"",
|
|
214
|
+
"patterns": [
|
|
215
|
+
{
|
|
216
|
+
"name": "constant.character.escape.proschi",
|
|
217
|
+
"match": "\\\\."
|
|
218
|
+
}
|
|
219
|
+
]
|
|
220
|
+
},
|
|
221
|
+
{
|
|
222
|
+
"name": "constant.numeric.json.proschi",
|
|
223
|
+
"match": "-?\\b\\d+(?:\\.\\d+)?(?:[eE][+-]?\\d+)?\\b"
|
|
224
|
+
},
|
|
225
|
+
{
|
|
226
|
+
"name": "constant.language.json.proschi",
|
|
227
|
+
"match": "\\b(?:true|false|null)\\b"
|
|
228
|
+
},
|
|
229
|
+
{
|
|
230
|
+
"name": "punctuation.separator.json.proschi",
|
|
231
|
+
"match": "[,:]"
|
|
232
|
+
}
|
|
233
|
+
]
|
|
234
|
+
}
|
|
235
|
+
}
|
|
236
|
+
}
|
package/package.json
ADDED
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "proschi",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"description": "Command-line checker and language server for Proschi architecture diagrams",
|
|
5
|
+
"license": "MIT",
|
|
6
|
+
"repository": {
|
|
7
|
+
"type": "git",
|
|
8
|
+
"url": "https://github.com/gvart/proschi.git",
|
|
9
|
+
"directory": "tooling"
|
|
10
|
+
},
|
|
11
|
+
"homepage": "https://gvart.github.io/proschi/",
|
|
12
|
+
"keywords": [
|
|
13
|
+
"proschi",
|
|
14
|
+
"architecture",
|
|
15
|
+
"diagram",
|
|
16
|
+
"language-server",
|
|
17
|
+
"lsp"
|
|
18
|
+
],
|
|
19
|
+
"type": "module",
|
|
20
|
+
"bin": {
|
|
21
|
+
"proschi": "dist/cli.cjs",
|
|
22
|
+
"proschi-language-server": "dist/server.cjs"
|
|
23
|
+
},
|
|
24
|
+
"files": [
|
|
25
|
+
"dist/cli.cjs",
|
|
26
|
+
"dist/server.cjs",
|
|
27
|
+
"grammar",
|
|
28
|
+
"schema",
|
|
29
|
+
"README.md",
|
|
30
|
+
"LICENSE"
|
|
31
|
+
],
|
|
32
|
+
"engines": {
|
|
33
|
+
"node": ">=18"
|
|
34
|
+
},
|
|
35
|
+
"scripts": {
|
|
36
|
+
"build": "node build.mjs",
|
|
37
|
+
"typecheck": "tsc --noEmit",
|
|
38
|
+
"pretest": "node build.mjs",
|
|
39
|
+
"test": "vitest run",
|
|
40
|
+
"package:vscode": "node build.mjs && cd vscode && vsce package --no-dependencies -o ../dist/proschi.vsix"
|
|
41
|
+
},
|
|
42
|
+
"devDependencies": {
|
|
43
|
+
"@types/node": "^24.19.1",
|
|
44
|
+
"@types/vscode": "~1.91.0",
|
|
45
|
+
"@vscode/vsce": "^4.0.0",
|
|
46
|
+
"ajv": "^8.20.0",
|
|
47
|
+
"esbuild": "^0.28.2",
|
|
48
|
+
"typescript": "~5.9.3",
|
|
49
|
+
"vitest": "^3.2.7",
|
|
50
|
+
"vscode-languageclient": "^10.1.2",
|
|
51
|
+
"vscode-languageserver": "^10.1.2",
|
|
52
|
+
"vscode-languageserver-textdocument": "^1.0.15",
|
|
53
|
+
"vscode-oniguruma": "^2.0.1",
|
|
54
|
+
"vscode-textmate": "^9.3.2"
|
|
55
|
+
}
|
|
56
|
+
}
|