← Back to team overview

kicad-developers team mailing list archive

Re: scripting version check

 

On 10/21/2015 2:49 AM, Lachlan Audas wrote:
> I can't see any way of scripting a version check in Kicad,  Pcbnew, or
> Eeschema,

There is no scripting for Eeschema or KiCad.  Only Pcbnew supports
scripting at this time.  Do you need the version of kicad or the pcb
file version.  If it's the pcb file version, you can get that by loading
a board file an calling BOARD::GetFileFormatVersionAtLoad().

> Most application  print version, given -v  or -version then exit.
> This allows script's to version check,  is there some other way for a
> shell script to check
> what version of Kicad it has ?,  if not, would there be any objection to
> adding
> a --version, which prints version and exit's for all the commands ?

In the short term, I would prefer that this be added to the swig
scripting generation code.  The GetBuildVersion() function would need to
be added.

In the long term, I'm not opposed to adding command line switches to
KiCad assuming it is done properly.  This means using wxCmdLineParser
and friends rather than some ad-hoc way of handling command line options.

> 
> Lachlan.
> 
> 
> 
> _______________________________________________
> Mailing list: https://launchpad.net/~kicad-developers
> Post to     : kicad-developers@xxxxxxxxxxxxxxxxxxx
> Unsubscribe : https://launchpad.net/~kicad-developers
> More help   : https://help.launchpad.net/ListHelp
> 


References