30#define ARG_FORMAT "--format"
35 .default_value( std::string(
"kicadsexpr" ) )
36 .help(
UTF8STDSTR(
_(
"Netlist output format, valid options: kicadsexpr, kicadxml, cadstar, orcadpcb2, spice, spicemodel" ) ) );
42 std::unique_ptr<JOB_EXPORT_SCH_NETLIST> netJob =
43 std::make_unique<JOB_EXPORT_SCH_NETLIST>(
true );
48 if( !wxFile::Exists( netJob->m_filename ) )
50 wxFprintf( stderr,
_(
"Schematic file does not exist or is not accessible\n" ) );
55 if( format ==
"kicadsexpr" )
59 else if( format ==
"kicadxml" )
63 else if( format ==
"cadstar" )
67 else if( format ==
"orcadpcb2" )
71 else if( format ==
"spice" )
75 else if( format ==
"spicemodel" )
81 wxFprintf( stderr,
_(
"Invalid format\n" ) );
argparse::ArgumentParser m_argParser
EXPORT_SCH_NETLIST_COMMAND()
int doPerform(KIWAY &aKiway) override
The internal handler that should be overloaded to implement command specific processing and work.
A minimalistic software bus for communications between various DLLs/DSOs (DSOs) within the same KiCad...
int ProcessJob(KIWAY::FACE_T aFace, JOB *job)
This file contains miscellaneous commonly used macros and functions.
static wxString FROM_UTF8(const char *cstring)
Convert a UTF8 encoded C string to a wxString for all wxWidgets build modes.
static const int ERR_ARGS
static const int ERR_INVALID_INPUT_FILE