@hybridlabor-api/bdb-hardware-pcb 0.1.0 → 0.1.1
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/config/mcp/antigravity.json +1 -1
- package/config/mcp/claude.json +1 -1
- package/config/mcp/codex.toml +1 -1
- package/installer.js +24 -1
- package/package.json +1 -1
package/config/mcp/claude.json
CHANGED
package/config/mcp/codex.toml
CHANGED
|
@@ -14,7 +14,7 @@ args = []
|
|
|
14
14
|
enabled = true
|
|
15
15
|
|
|
16
16
|
[mcp_servers.kicad.env]
|
|
17
|
-
KICAD_CLI_PATH = "
|
|
17
|
+
KICAD_CLI_PATH = "__KICAD_CLI_PATH__"
|
|
18
18
|
|
|
19
19
|
[mcp_servers.openscad]
|
|
20
20
|
command = "__INSTALL_DIR__/scripts/run_openscad_mcp.sh"
|
package/installer.js
CHANGED
|
@@ -71,6 +71,29 @@ function findPython() {
|
|
|
71
71
|
return null;
|
|
72
72
|
}
|
|
73
73
|
|
|
74
|
+
function findKicadCliPath() {
|
|
75
|
+
if (process.env.KICAD_CLI_PATH) return process.env.KICAD_CLI_PATH;
|
|
76
|
+
if (commandExists('kicad-cli')) return 'kicad-cli';
|
|
77
|
+
let candidates = [];
|
|
78
|
+
if (IS_WIN) {
|
|
79
|
+
const base = path.join(process.env.ProgramFiles || 'C:\\Program Files', 'KiCad');
|
|
80
|
+
if (fs.existsSync(base)) {
|
|
81
|
+
candidates = fs.readdirSync(base)
|
|
82
|
+
.map((v) => path.join(base, v, 'bin', 'kicad-cli.exe'))
|
|
83
|
+
.sort()
|
|
84
|
+
.reverse(); // prefer the highest version dir (e.g. 9.0 over 7.0)
|
|
85
|
+
}
|
|
86
|
+
} else if (process.platform === 'darwin') {
|
|
87
|
+
candidates = ['/Applications/KiCad/KiCad.app/Contents/MacOS/kicad-cli'];
|
|
88
|
+
} else {
|
|
89
|
+
candidates = ['/usr/bin/kicad-cli', '/usr/local/bin/kicad-cli'];
|
|
90
|
+
}
|
|
91
|
+
const found = candidates.find((p) => fs.existsSync(p));
|
|
92
|
+
if (found) return found;
|
|
93
|
+
log.warn('kicad-cli not found on PATH or in known install locations — set the KICAD_CLI_PATH env var manually once KiCad is installed.');
|
|
94
|
+
return 'kicad-cli';
|
|
95
|
+
}
|
|
96
|
+
|
|
74
97
|
function setupServerEnv(server, uvBin, pythonBin) {
|
|
75
98
|
const venvDir = path.join(server.dir, '.venv');
|
|
76
99
|
if (uvBin) {
|
|
@@ -166,7 +189,7 @@ function mcpServerEntries() {
|
|
|
166
189
|
kicad: {
|
|
167
190
|
command: kicad.command,
|
|
168
191
|
args: kicad.args,
|
|
169
|
-
env: { KICAD_CLI_PATH:
|
|
192
|
+
env: { KICAD_CLI_PATH: findKicadCliPath() },
|
|
170
193
|
},
|
|
171
194
|
openscad: {
|
|
172
195
|
command: openscad.command,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hybridlabor-api/bdb-hardware-pcb",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.1",
|
|
4
4
|
"description": "BDB Hardware & PCB — KiCad + OpenSCAD MCP servers and AI-era skills for schematic capture, PCB layout/routing, DFM sign-off, and parametric 3D enclosure design",
|
|
5
5
|
"main": "installer.js",
|
|
6
6
|
"bin": {
|