Git often shows me that many schematics were edited (usually ones which are hierarchical blocks) when I most certainly did not touch those blocks.
For example:
In schematic files, I often have a diff such as…
diff --git a/power/power_AP2210K_5V_0805.sch b/power/power_AP2210K_5V_0805.sch index 3f228ca..48c12f9 100644 --- a/power/power_AP2210K_5V_0805.sch +++ b/power/power_AP2210K_5V_0805.sch @@ -4,7 +4,7 @@ EELAYER 26 0 EELAYER END $Descr A4 11693 8268 encoding utf-8 -Sheet 22 55 +Sheet 22 56 Title "" Date "" Rev ""
…where the only change is this “Sheet xx xx” line.
What does this sheet line mean?
and can I have git ignore it by adding this to .gitattributes:
*.sch filter=kicad_sch
and these lines? (where I would need some help with sed)
git config --global filter.kicad_project.clean “sed -E ‘s/^Sheet.*$/Sheet/’”
git config --global filter.kicad_project.smudge cat