Re:Designing command-line interfaces
by antoarts on Friday August 05, 2011 @01:47PM
(#2850952)
I choose not to discuss implementation in that article, but you should never reinvent the wheel (poorly).
[ Parent
| on HN ]
I think a lot of people don't even realize such libraries are out there, or don't understand that there's a wheel being reinvented. ("It's just command line options. Why would you need a whole library to do that?")
Some of the wheels are also very big and crufty--- I would only link GNU Getopt to a C program if it were a Real Program, either with complex option processing or need for industrial-strength polish. For simple one-offs it's a lot easier to have 3 lines of strcmp(), and Getopt feels like overkill.