]> git.lyx.org Git - features.git/commit
Exit with error if no filename given to -e switch
authorScott Kostyshak <skostysh@lyx.org>
Thu, 28 Mar 2013 07:07:45 +0000 (03:07 -0400)
committerScott Kostyshak <skostysh@lyx.org>
Fri, 29 Mar 2013 05:57:29 +0000 (01:57 -0400)
commit6df4a7bb4018c7e13e191e59fdd5d9f768ce5592
treed54ab98b8670b030bb5d50f8d7f2825e3ddf7a62
parentcc138f6e68a006a6d8c760396ef30ede45155add
Exit with error if no filename given to -e switch

Before, 'lyx -e pdf2' would give no error and would exit with 0. A use
case is if a user has in a bash script the following command:

lyx -e pdf2 "${mylxyfile}" || exit 1

where 'lyx' is mispelled as 'lxy' and thus yields an empty
string. If LyX does not exit with an error, the script continues where
the user probably intends for it to stop.
src/LyX.cpp