From 80121e6e5aecea1faf5d33b0511ccc2827d820f4 Mon Sep 17 00:00:00 2001 From: jaseg Date: Sat, 29 Jan 2022 03:05:27 +0100 Subject: Make all layer matching tests run through --- gerbonara/gerber/layer_rules.py | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'gerbonara/gerber/layer_rules.py') diff --git a/gerbonara/gerber/layer_rules.py b/gerbonara/gerber/layer_rules.py index 871e44f..3d05cc0 100644 --- a/gerbonara/gerber/layer_rules.py +++ b/gerbonara/gerber/layer_rules.py @@ -12,7 +12,9 @@ MATCH_RULES = { 'bottom paste': r'.*\.gbp', 'inner copper': r'.*\.gp?([0-9]+)', 'mechanical outline': r'.*\.(gko|gm[0-9]+)', - 'drill unknown': r'.*\.(txt)', + # this rule is slightly generic to catch the drill files of things like geda and pcb-rnd that otherwise use altium's + # layer names. + 'drill unknown': r'.*\.(txt|drl|xln)', }, 'kicad': { @@ -113,10 +115,10 @@ MATCH_RULES = { 'drill nonplated': r'.*ThruHoleNonPlated.ncd', 'drill plated': r'.*ThruHolePlated.ncd', # list this last to prefer the actual excellon files - 'drill plated': r'.*DrillDrawingThrough.gdo', + #'drill plated': r'.*DrillDrawingThrough.gdo', # match these last to avoid shadowing other layers via substring match - 'top copper': r'.*Top.gdo', - 'bottom copper': r'.*Bottom.gdo', + 'top copper': r'.*[^enk]Top.gdo', + 'bottom copper': r'.*[^enk]Bottom.gdo', }, 'allegro': { -- cgit