Open kost opened 4 years ago
Thanks Kost. I am going to review this tonight - sorry for the delay!
I really appreciate the contribution.
We definitely want to get a test or two in here to validate the functionality. I would also like to see more functions and flatter code in this - that's a lot of indents to the right to consider.
I wonder if there is a way to add this functionality by default. I believe POSIX specifies that double dashes --
denotes an upcoming long flag while a single dash -
denotes a short flag (or multiple short flags). We could potentially enable this and call it flaggy version 2.0.0.
How would you feel about that?
I'm completely fine whatever you decide. Feel free to make it default or not. Also, feel free to flatter the code or test functionality.
If following option is enabled: flaggy.DefaultParser.ProcessMultipleShorts = true
following multiple options : -e -x -a -m -p -l can be written as: -exampl
Since, it breaks previous behaviour, it is added as an option to the parser.