ENH: CLI: add the gcode path check logic for cli

Change-Id: I424a93d9ca945598da861a1905da07ae14663157
This commit is contained in:
lane.wei 2023-04-14 15:21:11 +08:00 committed by Lane.Wei
parent 1a7b12fa38
commit 98f3aaa4bf
4 changed files with 17 additions and 1 deletions

View file

@ -2065,6 +2065,11 @@ int CLI::run(int argc, char **argv)
print->process();
}
if (printer_technology == ptFFF) {
std::string conflict_result = dynamic_cast<Print *>(print)->get_conflict_string();
if (!conflict_result.empty()) {
BOOST_LOG_TRIVIAL(error) << "plate "<< index+1<< ": found slicing result conflict!"<< std::endl;
flush_and_exit(CLI_GCODE_PATH_CONFLICTS);
}
// The outfile is processed by a PlaceholderParser.
//outfile = part_plate->get_tmp_gcode_path();
if (outfile_dir.empty()) {