库属性刷新 dry-run
元件属性批量刷新前的离线演练:精确匹配索引、排除键保护、布尔/直写/OtherProperty 分类与逐器件属性 diff;确认后才进编辑器。
Badges only claim the demo-run passed on that host; cross-host installation is handled by the adapter layer.
Preview gallery
Dry-run this attribute refresh rule: emit the match index, excluded-key hits and per-component attribute diffs; write nothing.
Content matches the files inside the package; extracted by the publish pipeline.
LCEDA library / symbol automation bundle
Offline core re-implemented from the Apache-2.0 LCEDA plaza extension eext-update-components-attributes-v3 (match/refresh rules). Library fetch and primitive mutation stay in-editor (references/procedures.md). Other library members (attribute editors, AI standardization, symbol extraction, grouping) are procedures.
Core
scripts/demo.mjs (Node >= 20, no deps):
- Match index: exact trimmed string equality on chosen baseAttr
(schematic side) vs matchAttr (library side);
Namestrips sub-part suffix/\.\d+$/. - Excluded keys never matched/written: Device, Designator, Name, Symbol, Footprint, 3D Model, 3D Model Title, 3D Model Transform.
- Update classes:
Add into BOM/Convert to PCB=== 'yes' -> boolean; Manufacturer / Manufacturer Part / Supplier / Supplier Part -> direct setters; everything else -> OtherProperty (string|number|boolean only). - Dry-run diff: per matched component, old attr vs library attr; unmatched components reported; no writes ever performed offline.
Run
node scripts/demo.mjs --out-dir <dir> [--input <json>]
Default scripts/fixtures/input.json; stdout = edaskills.report.v1;
artifacts attribute-diff.json, attribute-diff.csv.
Input: { baseAttr, matchAttr, components:[{designator, attrs:{...}}], devices:{result:{lists:[{uuid, display_title, attributes:{...}}]}} }
(devices shape = the extension's captured /api/v2/devices response).
When to use
- Before a library refresh: see exactly which attributes would change.
- Audit library consistency (missing manufacturer/MPN coverage).
Not for: delete-and-recreate mode ("删旧放新"), PCB device rebinding, batch multi-project tasks, or live library search.
Dependencies
Demo run
node v24.19.0 · 2026/11/19
- [info] ATTR_CHANGE (U1/Manufacturer): direct: "" -> "STMicroelectronics"
- [info] ATTR_CHANGE (U1/Manufacturer Part): direct: "" -> "STM32G031K8T6"
- [info] ATTR_CHANGE (U1/Supplier): direct: "" -> "LCSC"
- [info] ATTR_CHANGE (U1/Supplier Part): direct: "" -> "C529330"
- [info] ATTR_CHANGE (U1/Temperature Range): other: "" -> "-40..85"
FAQ
Ratings & reviews
Not rated0 ratings
Sign in to rate this skill.
Sign inVersions
- v1.0.0Latest464.9 KB
首发种子版本。