On Fri, May 07, 2004 at 01:56:47PM +0100, Ian Jackson wrote: > * I claim that the annotated behaviour is inferior, for two reasons: > > Firstly, it is less convenient. When md5sum is used in scripts and > the like, it is significantly easier to use if a script can get it > not to annotate the output for a single file on stdin, but just > produces the bare checksum (in hex, with a trailing newline, of > course). ... > * Opponents of my suggestion claim that the annotated behaviour is > superior because of some need to be `compatible' with coreutils > md5sum. ... > * Opponents of my suggestion have also claimed that it is not > appropriate for the Debian maintainer to make this change and that > instead I should get upstream coreutils to make the change first. ... > * There has been some suggestion that there is a need to trawl > through packages looking for ones which will break.
It's probably not unreasonable, however, for programs designed to work with specifically this md5sum interface to expect the interface to remain the same. Perhaps there should be a command line argument (of the single hyphen single character variety) to output just the md5sum? Perhaps this should also work when the file is specified by name? [I don't care about multiple file names -- either throw an error for that case, emit the md5sums in the order which corresponds to the command line, or produce a single md5sum representing the concatenation of the contents of all these files.] This does lose compatability with the historical md5sum, but I'm afraid we've already lost that. [Proper compatability would have the new behaviors available from options and the original behavior without any options, but at this point there are multiple original behaviors.] Thanks, -- Raul