Skip to content

Commit

Permalink
Merge pull request #197 from INTI-CMNB/add_exclude_from_bom
Browse files Browse the repository at this point in the history
Exclude components marked as "Exclude from BoM"
  • Loading branch information
SchrodingersGat authored Jan 30, 2024
2 parents 8fea8b1 + 547d593 commit fe8244f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion kibom/component.py
Original file line number Diff line number Diff line change
Expand Up @@ -355,7 +355,8 @@ def isFitted(self):
# First, check for the 'dnp' attribute (added in KiCad 7.0)
for child in self.element.getChildren():
if child.name == 'property':
if child.attributes.get('name', '').lower() == 'dnp':
name = child.attributes.get('name', '').lower()
if name == 'dnp' or name == 'exclude_from_bom':
return False

# Check the value field first
Expand Down

0 comments on commit fe8244f

Please sign in to comment.