leoheck / kiri

Kiri is a visual tool designed for reviewing schematics and layouts of KiCad projects that are version-controlled with Git.
MIT License
493 stars 35 forks source link

Check for kicad-cli does not work #76

Closed MarcelRobitaille closed 1 year ago

MarcelRobitaille commented 1 year ago

In generate_schematic_artifacts and generate_layout_artifacts there is a test for whether kicad-cli exists:

if [[ -f $(which kicad-cli 2>&1 > /dev/null) ]]

Since all output is piped into /dev/null, nothing is returned from which, so the test for the file's existence fails.

Instead of checking for the existence of /usr/bin/kicad-cli, I would recommend if type kicad-cli or if command -v kicad-cli.

Stack-Overflow: How can I check if a command exists in a shell script?

leoheck commented 1 year ago

This was just a quick test to make this kicad 7 working. please, check the latest version.