1. 26
  1.  

  2. 4

    Type

    lemon "-?"
    

    to get a list of options. Seriousy? What’s wrong with -h, which 99% of all other command line options offer?

    Apart from that it’s an interesting project! It’s nice to see that it has passed the test of time, and I can understand why the Sqlite-project has developed its own solution.

    1. 5

      Type lemon "-?" to get a list of options. Seriousy? What’s wrong with -h, which 99% of all other command line options offer?

      From the article:

      Lemon was originally written by Richard Hipp sometime in the late 1980s on a Sun4 Workstation using K&R C.

      Back in 1980 such conventions were not established, or ubiquitous, as today. At least lemon uses the POSIX utility argument convention of staring options with an hyphen. Common tools like dd do not even follow that convention, following instead IBM’s JCL syntax.

      BTW, the convention for DOS command tools still is foobar /?.

      1. 4

        Well I WAS about to say “well that should be easy to fix”, but then I took a look at the code… and you know what? I can’t find it. From looking at what calls OptPrint() it seems like it just prints out help when it gets an invalid flag, and so I think that’s just the author saying that -? will never be a valid flag. -h is currently also not a valid flag, so, that should work fine too!

        What irks me more is using -x for printing the version instead of -v. At least it does have an option to print the version, though. (I’m looking at you, OpenCV.)

      Stories with similar links:

      1. The Lemon Parser Generator via pushcx 5 years ago | 17 points | 1 comment