Il 05/10/2011 12:13, Alex Fernandez ha scritto:
As this option is new, only use it as default if you detect a LyX version
that supports it (currently only the development version).
Is there any way to get a simple version string from the command line?
The LyX format number would be ideal, as it does not need to be
parsed: a simple number comparison would be enough.

Guess you need to launch "lyx -version", then get *only the first line* and discard whatever comes after.

On Unix/Linux, you can use "lyx -version 2>&1 | head -n 1", but for maximum portability I guess you should encode that in Python (output comes on stderr, not stdout).

    T.

Reply via email to