Bruno Haible <br...@clisp.org> writes: > How about deriving the --version output from the copyright notice, for > those programs that consist of a single file and that are not written in C? [...] > + # Extract the last year from this file's copyright notice. > + sed_extract_last_year='s/^.*\([0-9]\{4\}\)[^0-9]*$/\1/' > + year=`sed -n -e /Copyright/p < "$progname" | sed -e 1q | sed -e > "$sed_extract_last_year"` [...] > > Advantage: Zero maintenance cost, as we rely on 'update-copyright' for the > copyright notice. > > Disadvantage: It's a violation of the boundary between program code and > meta-information. > > What do you think? Should we do this?
Seems fine to me unless anyone else disagrees. Would take a few more lines in Perl though, but not too bad. As far as I'm aware copyright in the US and EU expires a certain number of years after the author dies (though perhaps assignment to others, FSF in this case, complicates that). So I don't think the violation between program code and meta-information should have a meaningful impact. Not a lawyer, of course, so my word doesn't mean much. Collin