|
28 | 28 | MOD_VIRTUAL, W_PCBNOSCH, W_NONEEDSKIP, W_WRONGCHAR, name2make, W_TIMEOUT, W_KIAUTO, W_VARSCH, |
29 | 29 | NO_SCH_FILE, NO_PCB_FILE, W_VARPCB, NO_YAML_MODULE, WRONG_ARGUMENTS, FAILED_EXECUTE, W_VALMISMATCH, |
30 | 30 | MOD_EXCLUDE_FROM_POS_FILES, MOD_EXCLUDE_FROM_BOM, MOD_BOARD_ONLY, hide_stderr, W_MAXDEPTH, DONT_STOP, |
31 | | - W_BADREF, try_decode_utf8, MISSING_FILES, KICAD_VERSION_9_0_1, W_NOUUIDMAP) |
| 31 | + W_BADREF, try_decode_utf8, MISSING_FILES, KICAD_VERSION_9_0_1, W_NOUUIDMAP, W_SILLY) |
32 | 32 | from .error import PlotError, KiPlotConfigurationError, config_error, KiPlotError |
33 | 33 | from .config_reader import CfgYamlReader |
34 | 34 | from .pre_base import BasePreFlight |
@@ -1002,6 +1002,7 @@ def solve_schematic(base_dir, a_schematic=None, a_board_file=None, config=None, |
1002 | 1002 | schematic = schematics[0] |
1003 | 1003 | logger.info('Using SCH file: '+os.path.relpath(schematic)) |
1004 | 1004 | elif len(schematics) > 1: |
| 1005 | + is_silly = W_SILLY |
1005 | 1006 | # Look for a schematic with the same name as the config |
1006 | 1007 | if config: |
1007 | 1008 | if config[0] == '.': |
@@ -1035,12 +1036,13 @@ def solve_schematic(base_dir, a_schematic=None, a_board_file=None, config=None, |
1035 | 1036 | break |
1036 | 1037 | else: |
1037 | 1038 | # No way to select one, just take the first |
| 1039 | + is_silly = '' |
1038 | 1040 | if GS.ki6: |
1039 | 1041 | schematic = guess_ki6_sch(schematics) |
1040 | 1042 | if not schematic: |
1041 | 1043 | schematic = schematics[0] |
1042 | 1044 | msg = ' if you want to use another use -e option' if sug_e else '' |
1043 | | - logger.warning(W_VARSCH + 'More than one SCH file found in `'+base_dir+'`.\n' |
| 1045 | + logger.warning(is_silly+W_VARSCH+'More than one SCH file found in `'+base_dir+'`.\n' |
1044 | 1046 | ' Using '+schematic+msg+'.') |
1045 | 1047 | if schematic and not os.path.isfile(schematic): |
1046 | 1048 | GS.exit_with_error("Schematic file not found: "+schematic, NO_SCH_FILE) |
|
0 commit comments