-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use a command-line parsing library #33
Comments
Good point stating the possible attack vulerability. Again, as in #32 a short list of dependencies is desireable. Let's find a good compromise. 👍 |
I have not used any of these libs in particular but from an available documentation/feature set point of view, I think CLI11 is a good fit. I had also looked at argparse, but CI11 seemed to be a better fit |
OK I'll investigate using CL11. CL11 is header-only. Unlike some other (even header-only) libraries, it's not in MacPorts, Ubuntu, or Debian's main package repos. I'll investigate how it's usually integrated with CMake. |
@watkipet Since CMake v3.11, FetchContnet can be used to automatically download the repository as a dependency at configure time. This makes integrations pretty simple. Example (untested)
The relevant code will end up in build/_deps/cl11-build , build/_deps/cl11-src , and build/_deps/cl11-subbuild |
Initial work has been done, cli11 branch, CMake integration complete, and first pass in converting to CLI11 command-line parsing lib. I would welcome additional help |
The present command-line parsing is difficult to understand and brittle. It's also subject to all sorts of buffer-overrun attacks (bad news for people putting a web interface in front of Splat! who don't sanitize their input). I suggest using a the 3rd party library for parsing command line arguments. The ones that seem reasonable (in order of what I think I'd prefer) are:
Any concerns about using the 3rd party library? Any preference for one of these (or another)?
The text was updated successfully, but these errors were encountered: