File: bom_xref.sh

package info (click to toggle)
geda-gnetlist 20050313-1
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 2,092 kB
  • ctags: 702
  • sloc: lisp: 5,519; ansic: 3,809; sh: 3,647; makefile: 291
file content (10 lines) | stat: -rwxr-xr-x 247 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
#!/bin/sh
# ha ha

if [ -z $1 ] ; then
    echo "usage $0 geda-bom  # output on stdout"
    exit -1
fi    
cat $1 | sort -k1,1 |\
awk '!/device/{printf("%-5s %-20s %-20s %-20s\n", toupper($1), toupper($2), toupper($3), toupper($4));} /device/{}'