Tux / App-ccdiff

A colored diff that also colors inside changed lines
Artistic License 2.0
18 stars 5 forks source link

Should have more error messages #18

Closed raforg closed 3 years ago

raforg commented 3 years ago

Hi, if ccdiff is invoked with invalid command line options (e.g. --no-colors --no-colo), there is no error message about it. There is also no error message if either of the file arguments supplied is a directory rather than file. Error messages when encountering incorrect usage would be very helpful.

Tux commented 3 years ago
$ ccdiff --flubber x u
Unknown option: flubber
:

All options that are not reported as such are valid. Read the docs of Getopt::Long An error message for folders, block- and character devices and other imposibilities seems a goot idea. For now: just don't do that.

raforg commented 3 years ago

Thanks. Clearly, Getopt::Long is smarter than I expected. :-)

Tux commented 3 years ago

Warnings were added in 936d48677e31fc797b3bf14827f271e1a170196c and 936d48677e31fc797b3bf14827f271e1a170196c