@tscircuit/cli 0.1.709 → 0.1.710
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/dist/main.js +7 -2
- package/package.json +1 -1
- package/types/tscircuit.config.schema.json +40 -0
package/dist/main.js
CHANGED
|
@@ -73249,6 +73249,7 @@ var projectConfigSchema = z.object({
|
|
|
73249
73249
|
|
|
73250
73250
|
// lib/project-config/index.ts
|
|
73251
73251
|
var CONFIG_FILENAME = "tscircuit.config.json";
|
|
73252
|
+
var CONFIG_SCHEMA_URL = "https://cdn.jsdelivr.net/npm/@tscircuit/cli/types/tscircuit.config.schema.json";
|
|
73252
73253
|
var DEFAULT_BOARD_FILE_PATTERNS = [
|
|
73253
73254
|
"**/*.board.tsx",
|
|
73254
73255
|
"**/*.circuit.tsx",
|
|
@@ -73283,7 +73284,11 @@ var getSnapshotsDir = (projectDir = process.cwd()) => {
|
|
|
73283
73284
|
var saveProjectConfig = (config, projectDir = process.cwd()) => {
|
|
73284
73285
|
const configPath = path9.join(projectDir, CONFIG_FILENAME);
|
|
73285
73286
|
try {
|
|
73286
|
-
|
|
73287
|
+
const configWithSchema = {
|
|
73288
|
+
$schema: CONFIG_SCHEMA_URL,
|
|
73289
|
+
...config
|
|
73290
|
+
};
|
|
73291
|
+
fs6.writeFileSync(configPath, JSON.stringify(configWithSchema, null, 2));
|
|
73287
73292
|
return true;
|
|
73288
73293
|
} catch (error) {
|
|
73289
73294
|
console.error(`Error saving tscircuit config: ${error}`);
|
|
@@ -74112,7 +74117,7 @@ var getGlobalDepsInstallCommand = (packageManager, deps) => {
|
|
|
74112
74117
|
import { execSync as execSync2 } from "node:child_process";
|
|
74113
74118
|
var import_semver2 = __toESM2(require_semver2(), 1);
|
|
74114
74119
|
// package.json
|
|
74115
|
-
var version = "0.1.
|
|
74120
|
+
var version = "0.1.709";
|
|
74116
74121
|
var package_default = {
|
|
74117
74122
|
name: "@tscircuit/cli",
|
|
74118
74123
|
version,
|
package/package.json
CHANGED
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://cdn.jsdelivr.net/npm/@tscircuit/cli/types/tscircuit.config.schema.json",
|
|
4
|
+
"title": "TSCircuit Config",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"properties": {
|
|
8
|
+
"$schema": {
|
|
9
|
+
"type": "string",
|
|
10
|
+
"format": "uri",
|
|
11
|
+
"description": "JSON schema reference for the config file."
|
|
12
|
+
},
|
|
13
|
+
"mainEntrypoint": {
|
|
14
|
+
"type": "string",
|
|
15
|
+
"description": "Entry file for the circuit project."
|
|
16
|
+
},
|
|
17
|
+
"previewComponentPath": {
|
|
18
|
+
"type": "string",
|
|
19
|
+
"description": "Optional component path used for previews."
|
|
20
|
+
},
|
|
21
|
+
"ignoredFiles": {
|
|
22
|
+
"type": "array",
|
|
23
|
+
"items": {
|
|
24
|
+
"type": "string"
|
|
25
|
+
},
|
|
26
|
+
"description": "File globs to ignore."
|
|
27
|
+
},
|
|
28
|
+
"includeBoardFiles": {
|
|
29
|
+
"type": "array",
|
|
30
|
+
"items": {
|
|
31
|
+
"type": "string"
|
|
32
|
+
},
|
|
33
|
+
"description": "File globs to include as board files."
|
|
34
|
+
},
|
|
35
|
+
"snapshotsDir": {
|
|
36
|
+
"type": "string",
|
|
37
|
+
"description": "Directory path for storing snapshots."
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
}
|