kicad-library-install
Public Made by Adomby adom
Install/register a KiCad symbol or footprint library, and hand-generate .kicad_sch / .kicad_mod / .kicad_sym files, without silently corrupting the user's setup. Covers the five silent failure modes (lib tables rewritten on exit, UTF-8 BOM, lib_symbols sub-unit naming, 3D model Z datum, footprint name/filename mismatch) and the headless kicad-cli verification loop.
Install?
Install/register a KiCad symbol or footprint library, and hand-generate .kicad_sch / .kicad_mod / .kicad_sym files, without silently corrupting the user's setup. Covers the five silent failure modes (lib tables rewritten on exit, UTF-8 BOM, lib_symbols sub-unit naming, 3D model Z datum, footprint name/filename mismatch) and the headless kicad-cli verification loop.
adom-wiki pkg install adom/kicad-library-install
Latest: v1.0.1, published
README
markdownkicad-library-install
Install or register a KiCad symbol/footprint library, and hand-generate
.kicad_sch / .kicad_mod / .kicad_sym files, without silently corrupting
the user's setup.
Five failure modes, each of which produces no error message or a misleading one:
- Editing the lib tables while KiCad is running. They are read once at
startup and written back from memory on exit, so your entry is invisible to
the running instance and may be deleted when it closes. Symptom:
Cannot add U1 (footprint 'Nick:Part' not found)while the file on disk plainly contains the entry. - A UTF-8 BOM in a lib table. KiCad reports
has type UNINITIALIZED but expected SYMBOL; skippingand skips every library in the file. PowerShell'sSet-Content -Encoding UTF8writes one. - Namespacing
lib_symbolssub-units. Only the top-level symbol carries the library nickname; prefixing_0_1/_1_1rejects the whole schematic with an unlocatedFailed to load schematic. - A 3D model with a non-KiCad Z datum. KiCad expects origin at the seating plane; vendor STEP files are often top- or centre-referenced, so the part renders sunk into the board and the bad geometry bakes into downstream STEP/GLB exports.
- Footprint internal name ≠ filename. KiCad renames on save and references drift.
Also documents the headless kicad-cli verification loop that catches all of
them (the netlist export is the check that proves footprints resolve),
running a control against a known-good project before blaming your own file,
bisecting unlocated parse failures, and the defects to expect in vendor- or
wiki-sourced parts.
What a correctly installed library looks like

Both halves render from the installed library, the netlist resolves every
Footprint property to a real file, all 17 pins are present (including the
exposed pad KiCad's vendor symbol omitted), and the 3D body sits on the
board rather than inside it. Each of those is a separate check in this skill, and each fails silently when skipped.
Trap 4, drawn

Measure the STEP's Z extent before you swap a model. -h .. 0 means the origin
is at the top of the body and the part will sink; 0 .. +h is what KiCad
expects.
Companion to kicad-export-molecule
(shipping a finished board), this one covers getting the libraries and
generated files correct in the first place.