4 # In pcb-menu.res, add somewhere:
6 # {"grep" a={"G" "<Key>g"} ExecuteFile(/tmp/pcb.grep)}
8 # board.bom must be created using the bom2 backend
15 open(G, ">/tmp/pcb.grep");
16 print G "Unselect(All)\n";
20 ($refdes, $value, $footprint, $device, $voltage, $manufacturer, $manufacturer_part_number, $vendor, $vendor_part_number, $qty) = split(':', $_);
22 if ($first || /$reg/i) {
23 print "\033[34m" if $first;
24 printf("%-7s %-24s %-18s %s\n", $value, $manufacturer_part_number, $vendor_part_number, $refdes);
25 print "\033[0m" if $first;
27 for $r (split(',', $refdes)) {
28 print G "Select(ElementByName,$r)\n";
36 print "\n\033[32m$count parts\033[0m\n";