typespec-vscode 0.64.0-dev.1 → 0.64.0-dev.10

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.
@@ -12,6 +12,7 @@ granted herein, whether by implication, estoppel or otherwise.
12
12
  2. brace-expansion version 2.0.1 (https://github.com/juliangruber/brace-expansion)
13
13
  3. minimatch version 5.1.6 (https://github.com/isaacs/minimatch)
14
14
  4. semver version 7.6.3 (https://github.com/npm/node-semver)
15
+ 5. yaml version 2.5.1 (github:eemeli/yaml)
15
16
 
16
17
 
17
18
  %% balanced-match NOTICES AND INFORMATION BEGIN HERE
@@ -111,4 +112,32 @@ ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR
111
112
  IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
112
113
 
113
114
  =====================================================");
114
- END OF semver NOTICES AND INFORMATION
115
+ END OF semver NOTICES AND INFORMATION
116
+
117
+
118
+ %% yaml NOTICES AND INFORMATION BEGIN HERE
119
+ =====================================================
120
+ MIT License
121
+
122
+ Copyright (c) Microsoft Corporation. All rights reserved.
123
+
124
+ Permission is hereby granted, free of charge, to any person obtaining a copy
125
+ of this software and associated documentation files (the "Software"), to deal
126
+ in the Software without restriction, including without limitation the rights
127
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
128
+ copies of the Software, and to permit persons to whom the Software is
129
+ furnished to do so, subject to the following conditions:
130
+
131
+ The above copyright notice and this permission notice shall be included in all
132
+ copies or substantial portions of the Software.
133
+
134
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
135
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
136
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
137
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
138
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
139
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
140
+ SOFTWARE
141
+
142
+ =====================================================");
143
+ END OF yaml NOTICES AND INFORMATION
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "typespec-vscode",
3
- "version": "0.64.0-dev.1",
3
+ "version": "0.64.0-dev.10",
4
4
  "author": "Microsoft Corporation",
5
5
  "description": "TypeSpec language support for VS Code",
6
6
  "homepage": "https://typespec.io",
@@ -32,10 +32,18 @@
32
32
  "activationEvents": [
33
33
  "onLanguage:typespec",
34
34
  "onCommand:typespec.restartServer",
35
+ "onCommand:typespec.createProject",
35
36
  "workspaceContains:**/tspconfig.yaml"
36
37
  ],
37
38
  "icon": "./icons/logo.png",
38
39
  "contributes": {
40
+ "viewsWelcome": [
41
+ {
42
+ "view": "explorer",
43
+ "contents": "You may [open a folder](command:vscode.openFolder) of an existing TypeSpec project; or create a new TypeSpec project in VS Code.\n[Create TypeSpec Project](command:typespec.createProject)\nTo manually create a TypeSpec project, follow [this guide](https://typespec.io/docs/).",
44
+ "when": "!workspaceFolderCount"
45
+ }
46
+ ],
39
47
  "languages": [
40
48
  {
41
49
  "id": "typespec",
@@ -63,9 +71,33 @@
63
71
  "typespec.tsp-server.path": {
64
72
  "type": "string",
65
73
  "default": "",
66
- "description": "Path to `tsp-server` command that runs the TypeSpec language server.\n\nIf not specified, then `tsp-server` found on PATH is used.\n\nExample (User): /usr/local/bin/tsp-server\nExample (Workspace): ${workspaceFolder}/node_modules/@typespec/compiler",
74
+ "description": "Path to 'tsp-server' command that runs the TypeSpec language server. If not specified, then 'tsp-server' will be resolved in following sequence:\n\n1. from workspace node_modules folder\nExample: ${workspaceFolder}/node_modules/@typespec/compiler\n\n2. from PATH environment variable\nExample: /usr/local/bin/tsp-server",
67
75
  "scope": "machine-overridable"
68
76
  },
77
+ "typespec.initTemplatesUrls": {
78
+ "type": "array",
79
+ "default": [],
80
+ "description": "List of URLs to fetch templates from when creating a new project.",
81
+ "scope": "machine-overridable",
82
+ "items": {
83
+ "type": "object",
84
+ "required": [
85
+ "name",
86
+ "url"
87
+ ],
88
+ "properties": {
89
+ "name": {
90
+ "type": "string",
91
+ "description": "Name of the template."
92
+ },
93
+ "url": {
94
+ "type": "string",
95
+ "description": "URL to fetch the template from."
96
+ }
97
+ },
98
+ "additionalProperties": false
99
+ }
100
+ },
69
101
  "typespec.trace.server": {
70
102
  "scope": "window",
71
103
  "type": "string",
@@ -108,8 +140,39 @@
108
140
  "command": "typespec.showOutputChannel",
109
141
  "title": "Show Output Channel",
110
142
  "category": "TypeSpec"
143
+ },
144
+ {
145
+ "command": "typespec.generateCode",
146
+ "title": "Generate from TypeSpec",
147
+ "category": "TypeSpec"
148
+ },
149
+ {
150
+ "command": "typespec.createProject",
151
+ "title": "Create TypeSpec Project",
152
+ "category": "TypeSpec"
153
+ },
154
+ {
155
+ "command": "typespec.installGlobalCompilerCli",
156
+ "title": "Install TypeSpec Compiler/CLI globally",
157
+ "category": "TypeSpec"
111
158
  }
112
159
  ],
160
+ "menus": {
161
+ "explorer/context": [
162
+ {
163
+ "command": "typespec.generateCode",
164
+ "when": "explorerResourceIsFolder || resourceLangId == typespec",
165
+ "group": "code_generation"
166
+ }
167
+ ],
168
+ "editor/context": [
169
+ {
170
+ "command": "typespec.generateCode",
171
+ "when": "resourceLangId == typespec",
172
+ "group": "code_generation"
173
+ }
174
+ ]
175
+ },
113
176
  "semanticTokenScopes": [
114
177
  {
115
178
  "scopes": {
@@ -158,6 +221,7 @@
158
221
  "@types/mocha": "^10.0.9",
159
222
  "@types/node": "~22.7.9",
160
223
  "@types/vscode": "~1.94.0",
224
+ "@types/semver": "^7.5.8",
161
225
  "@typespec/compiler": "~0.63.0 || >=0.64.0-dev <0.64.0",
162
226
  "@typespec/internal-build-utils": "~0.63.0 || >=0.64.0-dev <0.64.0",
163
227
  "@vitest/coverage-v8": "^2.1.5",
@@ -170,7 +234,9 @@
170
234
  "rollup": "~4.24.0",
171
235
  "typescript": "~5.6.3",
172
236
  "vitest": "^2.1.5",
173
- "vscode-languageclient": "~9.0.1"
237
+ "vscode-languageclient": "~9.0.1",
238
+ "semver": "^7.6.3",
239
+ "yaml": "~2.5.1"
174
240
  },
175
241
  "dependencies": {},
176
242
  "peerDependencies": {},
Binary file