You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I found this library useful to automatically update schematics. Thanks for this!
I track my changes on git, and try to track changes like code. When skip write schematics, it writes split lines. This formatting differs from KiCAD, which uses nested indentation. This makes it difficult to use the output directly with git diff - primarily to see whether the script did exactly what was intended.
E.g. a file written by skip on my system has this as the first line
The order of elements saved by both KiCAD and skip library seems to be same, but the difference is in the indentation and line formatting. To get clean git diffs, I now open the file generated by skip, and save the file. Then commit the schematic. Fixing the schematic write seems useful.
Fixing schematic write - writeTree() in sexp/util.py I suppose would resolve this. I see some comments there that I don't understand :) Any guidance appreciated. I can submit a PR.
The text was updated successfully, but these errors were encountered:
From KiCAD's output, there may be some formatting gotchas. "xy" lists are clearly handled differently. One place I saw custom logic was when it split up "xy" lists in "polyline" into two lines.
EDIT: Looking at the source code of KiCAD, it is clear that logic specific to the type of symbols is involved (arc, circle, polygon, bezier etc). So making this happen would require the writeTree functionality to mirror KiCAD logic,
I found this library useful to automatically update schematics. Thanks for this!
I track my changes on git, and try to track changes like code. When skip write schematics, it writes split lines. This formatting differs from KiCAD, which uses nested indentation. This makes it difficult to use the output directly with git diff - primarily to see whether the script did exactly what was intended.
E.g. a file written by skip on my system has this as the first line
When KiCAD saves the file, I get
The order of elements saved by both KiCAD and skip library seems to be same, but the difference is in the indentation and line formatting. To get clean git diffs, I now open the file generated by skip, and save the file. Then commit the schematic. Fixing the schematic write seems useful.
Fixing schematic write - writeTree() in sexp/util.py I suppose would resolve this. I see some comments there that I don't understand :) Any guidance appreciated. I can submit a PR.
The text was updated successfully, but these errors were encountered: