From cd63d12c7f69514de90343b0c80bf7b43a96607a Mon Sep 17 00:00:00 2001 From: Michael Smith Date: Tue, 2 Jul 2024 22:16:18 -0400 Subject: [PATCH] chore: add ability to generate one board jobs --- hardware/panelize.sh | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/hardware/panelize.sh b/hardware/panelize.sh index 254f7d2..e2cfbe6 100644 --- a/hardware/panelize.sh +++ b/hardware/panelize.sh @@ -2,8 +2,10 @@ MODULE=${1%/} OUTPUT=$2 +PANELIZE=$3 SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd ) MODULE_DIR="${SCRIPT_DIR}/${MODULE}" +PCB="${MODULE_DIR}/${MODULE}.kicad_pcb" if [ -z "$MODULE" ]; then echo "Usage: $0 [output-dir]" @@ -14,5 +16,8 @@ if [ -z "$OUTPUT" ]; then OUTPUT=$HOME/pdusb-panelized fi -kikit panelize -p "${MODULE_DIR}/panelize.json" -p :jlcTooling "${MODULE_DIR}/${MODULE}.kicad_pcb" "$OUTPUT/panel.kicad_pcb" -kikit fab jlcpcb --no-drc --assembly --schematic "${MODULE_DIR}/${MODULE}.kicad_sch" "$OUTPUT/panel.kicad_pcb" "$OUTPUT/" \ No newline at end of file +if [ -z "$PANELIZE" ]; then + kikit panelize -p "${MODULE_DIR}/panelize.json" -p :jlcTooling "${MODULE_DIR}/${MODULE}.kicad_pcb" "$OUTPUT/panel.kicad_pcb" + PCB="$OUTPUT/panel.kicad_pcb" +fi +kikit fab jlcpcb --no-drc --assembly --schematic "${MODULE_DIR}/${MODULE}.kicad_sch" "$PCB" "$OUTPUT/" \ No newline at end of file