Skip to content
Snippets Groups Projects
Commit 63f59737 authored by Martin Vítek's avatar Martin Vítek
Browse files

Add generate.sh

parent 3a20ef63
No related branches found
No related tags found
No related merge requests found
#!/bin/bash
project="servo-headlight-control"
schema="HW/servo-headlight-control.sch"
board="HW/servo-headlight-control.brd"
# Check, if there are changes to be commited
do_sch=$(git status --porcelain | awk '/^M/ && /.sch/')
do_brd=$(git status --porcelain | awk '/^M/ && /.brd/')
# Generate schema image
if [ "$do_sch" ]; then
eagle -C "set confirm yes;
export image $project-schema.png 300;
set confirm no;
quit;" $schema
fi
# Generate board image
if [ "$do_brd" ]; then
eagle -C "set confirm yes;
display None;
display Top Bottom Pads Vias Unrouted Dimension tPlace bPlace tName bNames Measures Document tDocu bDocu;
ratsnest;
export image $project-pcb.png 300;
set confirm no;
quit;" $board
fi
# Generate schema PDF
if [ "$do_sch" ]; then
eagle -C "set confirm yes;
print -1 -mirror -caption -rotate -upsidedown -black -solid landscape paper A4 file %N-schema.pdf;
set confirm no;
quit;" $schema
mv HW/*.pdf .
fi
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment