Tracktion / pluginval

Cross platform plugin testing and validation tool

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Cannot use --arg=value style of CLI args

falkTX opened this issue · comments

It is typical for CLI tools to accept both --arg=value and --arg value style of CLI arguments, but pluginval fails here.
If using something like getopt this is handled for us, seems weird to not have this working.

So here is a request for such functionality.

Complete CLI output for posterity:

% pluginval --strictness-level=10 ...
JUCE v7.0.1
Missing strictness level argument! (Must be between 1 - 10)

PS: tool does not close when provided CLI args are not recognized, I need to use Ctrl+C to stop it.

I'm using juce::ArgumentList for this which actually defaults to the --arg=value style but I'm not really a fan because it makes it more complex to pass multiple arguments. So I actually provide a work around to add back the --arg value style as it was more familiar to me and how man pages are usually displayed.

I don't think Windows natively comes with getopt and the API looks a bit verbose for what I needed.
Maybe an approach that would work would be to use the standard juce::ArgumentList approach which works with --arg=value but parse the passed in command line to add any missing = to get it in to that form. That might work.

PS: tool does not close when provided CLI args are not recognized, I need to use Ctrl+C to stop it.
Thanks, I'll add this to the list to look in to.

PS: tool does not close when provided CLI args are not recognized, I need to use Ctrl+C to stop it.

Fixed here:
bdd5f6a