short option with optional arg doesn't accept strings "-foobar" or "--foobar" as args while short option with manadatory arg does
Hello!
Let's assume s
to be short option accepting mandatory arg and t
to be short option accepting optional arg:
$ proganame -s "-foobar" # Works
$ proganame -t "-foobar" # Doesn't work
$ proganame -s "--foobar" # Works
$ proganame -t "--foobar" # Doesn't work
So, how to pass strings like "-foobar" and "--foobar" to short option accepting optional argument?
Edited by Avinash Sonawane