dragon icon indicating copy to clipboard operation
dragon copied to clipboard

Dragon can't handle combined flags

Open hi-im-buggy opened this issue 3 years ago • 1 comments

Bug

Currently dragon cannot handle combined flags in the arguments passed to it on the shell, for eg:

dragon-drag-and-drop -tk

Expected behaviour

dragon launches with -t and -k flags

Actual behaviour

dragon returns the following error

dragon-drag-and-drop: error: unknown option `-tk'.
Usage: dragon-drag-and-drop [OPTIONS] FILENAME

Potential fix

This can be fixed by using the standard getopt C library. I'd be happy to write PR for the same.

hi-im-buggy avatar Feb 26 '22 15:02 hi-im-buggy

This can be fixed by using the standard getopt C library. I'd be happy to write PR for the same.

Standard POSIX getopt doesn't support long-options. And getopt_long is GNU extension. I don't think it makes sense to use GNU extension for negligible benefit, typing -t -k isn't too bad.

N-R-K avatar May 06 '22 09:05 N-R-K